From af2ada92589a435bf130082a2bb5d3fda55de7b4 Mon Sep 17 00:00:00 2001 From: Alexander Mai Date: Sat, 14 Nov 2015 14:44:27 +0100 Subject: [PATCH] #6692 False positive: Hidden member variable - parent class with same name in different namespace. Add regression test for FP which got fixed in 1.70 already --- test/testclass.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/test/testclass.cpp b/test/testclass.cpp index 6e762c57d..4b5967dcd 100644 --- a/test/testclass.cpp +++ b/test/testclass.cpp @@ -367,6 +367,18 @@ private: "};"); ASSERT_EQUALS("", errout.str()); + // #6692 + checkDuplInheritedMembers("namespace test1 {\n" + " struct SWibble{};\n" + " typedef SWibble wibble;\n" + "}\n" + "namespace test2 {\n" + " struct SWibble : public test1::wibble {\n" + " int Value;\n" + " };\n" + "}"); + ASSERT_EQUALS("", errout.str()); + } void checkCopyConstructor(const char code[]) {