Skip to content
This repository was archived by the owner on Mar 30, 2021. It is now read-only.

Commit 8cebd4d

Browse files
committed
Added failing test.
1 parent 0c38f81 commit 8cebd4d

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

unittests/AST/StructuralEquivalenceTest.cpp

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -403,6 +403,15 @@ TEST_F(StructuralEquivalenceFunctionTest,
403403
EXPECT_TRUE(testStructuralMatch(t));
404404
}
405405

406+
TEST_F(StructuralEquivalenceFunctionTest,
407+
ParameterInDifferentScopeShouldBeInequal) {
408+
auto t = makeNamedDecls(
409+
"namespace A { class X; } void foo(A::X &x);",
410+
"namespace B { class X; } void foo(B::X &x);",
411+
Lang_CXX);
412+
EXPECT_FALSE(testStructuralMatch(t));
413+
}
414+
406415
struct StructuralEquivalenceCXXMethodTest : StructuralEquivalenceTest {
407416
};
408417

0 commit comments

Comments
 (0)