@@ -2534,19 +2534,16 @@ TEST(NullPointerConstants, Basic) {
2534
2534
}
2535
2535
2536
2536
TEST (HasExternalFormalLinkage, Basic) {
2537
- EXPECT_TRUE (matches (" int a = 0;" , namedDecl (hasExternalFormalLinkage ())));
2538
- EXPECT_TRUE (
2539
- notMatches (" static int a = 0;" , namedDecl (hasExternalFormalLinkage ())));
2537
+ EXPECT_TRUE (matches (" int a = 0;" ,
2538
+ namedDecl (hasName (" a" ), hasExternalFormalLinkage ())));
2539
+ EXPECT_TRUE (notMatches (" static int a = 0;" ,
2540
+ namedDecl (hasName (" a" ), hasExternalFormalLinkage ())));
2540
2541
EXPECT_TRUE (notMatches (" static void f(void) { int a = 0; }" ,
2541
- namedDecl (hasExternalFormalLinkage ())));
2542
- EXPECT_TRUE (matches (" void f(void) { int a = 0; }" ,
2543
- namedDecl (hasExternalFormalLinkage ())));
2544
-
2545
- // Despite having internal semantic linkage, the anonymous namespace member
2546
- // has external linkage because the member has a unique name in all
2547
- // translation units.
2548
- EXPECT_TRUE (matches (" namespace { int a = 0; }" ,
2549
- namedDecl (hasExternalFormalLinkage ())));
2542
+ namedDecl (hasName (" a" ), hasExternalFormalLinkage ())));
2543
+ EXPECT_TRUE (notMatches (" void f(void) { int a = 0; }" ,
2544
+ namedDecl (hasName (" a" ), hasExternalFormalLinkage ())));
2545
+ EXPECT_TRUE (notMatches (" namespace { int a = 0; }" ,
2546
+ namedDecl (hasName (" a" ), hasExternalFormalLinkage ())));
2550
2547
}
2551
2548
2552
2549
TEST (HasDefaultArgument, Basic) {
0 commit comments