• Home
  • Raw
  • Download

Lines Matching refs:hasName

166       Program, callExpr(allOf(callee(functionDecl(hasName("f"))),  in TEST_P()
171 allOf(callee(functionDecl(hasName("f"))), in TEST_P()
173 hasArgument(1, hasType(pointsTo(recordDecl(hasName("T"))))))))); in TEST_P()
176 callee(functionDecl(hasName("f"))), in TEST_P()
178 hasArgument(1, hasType(pointsTo(recordDecl(hasName("T"))))), in TEST_P()
182 callee(functionDecl(hasName("f"))), in TEST_P()
184 hasArgument(1, hasType(pointsTo(recordDecl(hasName("T"))))), in TEST_P()
195 DeclarationMatcher HasClassX = recordDecl(has(recordDecl(hasName("X")))); in TEST_P()
200 recordDecl(hasName("Y"), has(recordDecl(hasName("X")))); in TEST_P()
212 recordDecl(has(recordDecl(has(recordDecl(hasName("X"))), in TEST_P()
213 has(recordDecl(hasName("Y"))), hasName("Z"))), in TEST_P()
214 has(recordDecl(has(recordDecl(hasName("A"))), in TEST_P()
215 has(recordDecl(hasName("B"))), hasName("C"))), in TEST_P()
216 hasName("F")); in TEST_P()
269 anyOf(has(recordDecl(anyOf(has(recordDecl(hasName("X"))), in TEST_P()
270 has(recordDecl(hasName("Y"))), hasName("Z")))), in TEST_P()
271 has(recordDecl(anyOf(hasName("C"), has(recordDecl(hasName("A"))), in TEST_P()
272 has(recordDecl(hasName("B")))))), in TEST_P()
273 hasName("F"))); in TEST_P()
293 cxxRecordDecl(isDerivedFrom("Y"), unless(hasName("X"))); in TEST_P()
302 recordDecl(hasName("X"), has(recordDecl(hasName("Z"))), in TEST_P()
303 unless(has(recordDecl(hasName("Y"))))); in TEST_P()
309 namedDecl(hasName("Foo"), unless(recordDecl())); in TEST_P()
336 recordDecl(hasDescendant(recordDecl(hasName("X"))), hasName("Z")); in TEST_P()
348 hasDescendant(recordDecl(has(recordDecl(hasName("Y"))), hasName("X"))), in TEST_P()
349 hasName("Z")); in TEST_P()
370 hasDescendant(recordDecl(hasName("Y"))), hasName("X"))), in TEST_P()
371 hasName("Z")); in TEST_P()
395 auto Name = hasName("i"); in TEST_P()
438 anyOf(hasName("Y"), allOf(isDerivedFrom("X"), hasName("Z")))); in TEST_P()
446 recordDecl(anyOf(hasName("X"), hasName("Y"), hasName("Z"), hasName("U"))); in TEST_P()
451 hasName("X"), hasName("Y"), hasName("Z"), hasName("U"), hasName("V"))); in TEST_P()
487 cxxRecordDecl(hasName("Z"), isDerivedFrom("X")); in TEST_P()
513 cxxRecordDecl(hasName("Z"), isDerivedFrom("X")); in TEST_P()
515 cxxRecordDecl(hasName("Z"), isDirectlyDerivedFrom("X")); in TEST_P()
637 cxxRecordDecl(isDerivedFrom(recordDecl(hasName("Some")))))); in TEST_P()
644 cxxRecordDecl(hasName("B"), isDerivedFrom(recordDecl(hasName("A")))))); in TEST_P()
651 cxxRecordDecl(hasName("B"), in TEST_P()
652 isDirectlyDerivedFrom(recordDecl(hasName("A")))))); in TEST_P()
668 varDecl(hasName("z_float"), in TEST_P()
672 varDecl(hasName("z_float"), in TEST_P()
676 varDecl(hasName("z_char"), in TEST_P()
693 varDecl(hasName("z_float"), in TEST_P()
697 varDecl(hasName("z_float"), in TEST_P()
701 varDecl(hasName("z_char"), in TEST_P()
711 cxxRecordDecl(isDerivedFrom(recordDecl(hasName("X")).bind("test"))))); in TEST_P()
716 cxxRecordDecl(isDerivedFrom(namedDecl(hasName("X")))))); in TEST_P()
778 objcInterfaceDecl(hasName("Z"), isDerivedFrom("X")); in TEST_P()
780 objcInterfaceDecl(hasName("Z"), isDirectlyDerivedFrom("X")); in TEST_P()
852 DeclarationMatcher ClassX = has(recordDecl(hasName("::X")).bind("x")); in TEST_P()
863 recordDecl(hasName("A"), has(recordDecl(hasName("B")).bind("b")))); in TEST_P()
870 callExpr(callee(cxxMethodDecl(hasName("x")))).bind("x"); in TEST_P()
894 DeclarationMatcher ClassX = recordDecl(hasName("X")).bind("x"); in TEST_P()
898 anyOf(recordDecl(hasName("A"), hasDescendant(ClassX)), in TEST_P()
899 recordDecl(hasName("B"), hasDescendant(ClassX)))), in TEST_P()
981 auto M = varDecl(hasName("X"), hasLocalStorage()); in TEST_P()
988 auto M = varDecl(hasName("X"), hasGlobalStorage()); in TEST_P()
1006 EXPECT_TRUE(matches(T, varDecl(hasName("x"), hasAutomaticStorageDuration()))); in TEST_P()
1008 notMatches(T, varDecl(hasName("y"), hasAutomaticStorageDuration()))); in TEST_P()
1010 notMatches(T, varDecl(hasName("a"), hasAutomaticStorageDuration()))); in TEST_P()
1012 EXPECT_TRUE(matches(T, varDecl(hasName("y"), hasStaticStorageDuration()))); in TEST_P()
1013 EXPECT_TRUE(matches(T, varDecl(hasName("a"), hasStaticStorageDuration()))); in TEST_P()
1014 EXPECT_TRUE(matches(T, varDecl(hasName("b"), hasStaticStorageDuration()))); in TEST_P()
1015 EXPECT_TRUE(matches(T, varDecl(hasName("c"), hasStaticStorageDuration()))); in TEST_P()
1016 EXPECT_TRUE(notMatches(T, varDecl(hasName("x"), hasStaticStorageDuration()))); in TEST_P()
1019 EXPECT_TRUE(notMatches(T, varDecl(hasName("x"), hasThreadStorageDuration()))); in TEST_P()
1020 EXPECT_TRUE(notMatches(T, varDecl(hasName("y"), hasThreadStorageDuration()))); in TEST_P()
1021 EXPECT_TRUE(notMatches(T, varDecl(hasName("a"), hasThreadStorageDuration()))); in TEST_P()
1025 EXPECT_TRUE(matches("void f(int i) {}", varDecl(hasName("i")))); in TEST_P()
1035 sizeOfExpr(hasArgumentOfType(hasDeclaration(recordDecl(hasName("A"))))))); in TEST_P()
1038 hasDeclaration(recordDecl(hasName("string"))))))); in TEST_P()
1228 varDecl(hasType(references(recordDecl(hasName("X"))))); in TEST_P()
1292 functionDecl(hasName("~A"), isDefaulted()))); in TEST_P()
1294 functionDecl(hasName("~B"), isDefaulted()))); in TEST_P()
1303 notMatches("void Func();", functionDecl(hasName("Func"), isDeleted()))); in TEST_P()
1305 functionDecl(hasName("Func"), isDeleted()))); in TEST_P()
1343 varDecl(hasName("foo"), isConstexpr()))); in TEST_P()
1345 functionDecl(hasName("bar"), isConstexpr()))); in TEST_P()
1490 cxxMethodDecl(isVirtual(), hasName("::X::f")))); in TEST_P()
1501 cxxMethodDecl(isVirtualAsWritten(), hasName("::A::f")))); in TEST_P()
1505 cxxMethodDecl(isVirtualAsWritten(), hasName("::B::f")))); in TEST_P()
1514 cxxMethodDecl(isPure(), hasName("::X::f")))); in TEST_P()
1571 cxxMethodDecl(isOverride(), hasName("::Y::f")))); in TEST_P()
1574 cxxMethodDecl(isOverride(), hasName("::X::f")))); in TEST_P()
1582 cxxMethodDecl(isOverride(), hasName("::Y::f")))); in TEST_P()
1592 cxxConstructExpr(hasArgument(0, declRefExpr(to(varDecl(hasName("y"))))))); in TEST_P()
1608 hasArgument(42, declRefExpr(to(varDecl(hasName("y"))))))); in TEST_P()
1644 has(cxxMethodDecl(hasName("mem")).bind("templMem")))))))))), in TEST()
1664 has(fieldDecl(hasName("mem")).bind("templMem")))))))))), in TEST()
1681 has(varDecl(hasName("mem")).bind("templMem")))))))))), in TEST()
1710 translationUnitDecl(has(cxxRecordDecl(hasName("mem"))), in TEST()
1715 translationUnitDecl(has(cxxRecordDecl(hasName("mem")).bind("templMem")), in TEST()
1735 0, declRefExpr(to(varDecl(hasName("y")))))))); in TEST()
1738 0, declRefExpr(to(varDecl(hasName("x")))))))); in TEST()
1771 cxxMethodDecl(isImplicit(), hasName("operator=")))); in TEST_P()
1924 recordDecl(hasName("a::b::C")))); in TEST_P()
1926 recordDecl(hasName("::a::b::C")))); in TEST_P()
1928 recordDecl(hasName("b::C")))); in TEST_P()
1930 recordDecl(hasName("C")))); in TEST_P()
1932 recordDecl(hasName("c::b::C")))); in TEST_P()
1934 recordDecl(hasName("a::c::C")))); in TEST_P()
1936 recordDecl(hasName("a::b::A")))); in TEST_P()
1938 recordDecl(hasName("::C")))); in TEST_P()
1940 recordDecl(hasName("::b::C")))); in TEST_P()
1942 recordDecl(hasName("z::a::b::C")))); in TEST_P()
1944 recordDecl(hasName("a+b::C")))); in TEST_P()
1946 recordDecl(hasName("C")))); in TEST_P()
1955 recordDecl(hasName("A::B::C")))); in TEST_P()
1957 recordDecl(hasName("::A::B::C")))); in TEST_P()
1959 recordDecl(hasName("B::C")))); in TEST_P()
1961 matches("class A { class B { class C; }; };", recordDecl(hasName("C")))); in TEST_P()
1963 recordDecl(hasName("c::B::C")))); in TEST_P()
1965 recordDecl(hasName("A::c::C")))); in TEST_P()
1967 recordDecl(hasName("A::B::A")))); in TEST_P()
1969 recordDecl(hasName("::C")))); in TEST_P()
1971 recordDecl(hasName("::B::C")))); in TEST_P()
1973 recordDecl(hasName("z::A::B::C")))); in TEST_P()
1975 recordDecl(hasName("A+B::C")))); in TEST_P()
1984 EXPECT_TRUE(matches(code, recordDecl(hasName("a::b::C")))); in TEST_P()
1985 EXPECT_TRUE(matches(code, recordDecl(hasName("a::C")))); in TEST_P()
1986 EXPECT_TRUE(matches(code, recordDecl(hasName("::a::b::C")))); in TEST_P()
1987 EXPECT_TRUE(matches(code, recordDecl(hasName("::a::C")))); in TEST_P()
1997 matches(code, recordDecl(hasName("a::(anonymous namespace)::C")))); in TEST_P()
1998 EXPECT_TRUE(matches(code, recordDecl(hasName("a::C")))); in TEST_P()
2000 matches(code, recordDecl(hasName("::a::(anonymous namespace)::C")))); in TEST_P()
2001 EXPECT_TRUE(matches(code, recordDecl(hasName("::a::C")))); in TEST_P()
2010 recordDecl(hasName("A::(anonymous class)::C")))); in TEST_P()
2012 recordDecl(hasName("::A::(anonymous class)::C")))); in TEST_P()
2014 recordDecl(hasName("::A::C")))); in TEST_P()
2016 recordDecl(hasName("A::(anonymous struct)::C")))); in TEST_P()
2018 recordDecl(hasName("::A::(anonymous struct)::C")))); in TEST_P()
2020 recordDecl(hasName("::A::C")))); in TEST_P()
2030 EXPECT_TRUE(matches(code, varDecl(hasName("i")))); in TEST_P()
2031 EXPECT_FALSE(matches(code, varDecl(hasName("F()::i")))); in TEST_P()
2033 EXPECT_TRUE(matches(code, fieldDecl(hasName("m")))); in TEST_P()
2034 EXPECT_TRUE(matches(code, fieldDecl(hasName("S::m")))); in TEST_P()
2035 EXPECT_TRUE(matches(code, fieldDecl(hasName("F(int)::S::m")))); in TEST_P()
2036 EXPECT_TRUE(matches(code, fieldDecl(hasName("a::F(int)::S::m")))); in TEST_P()
2037 EXPECT_TRUE(matches(code, fieldDecl(hasName("::a::F(int)::S::m")))); in TEST_P()
2047 EXPECT_TRUE(matches(code, functionDecl(hasName("test")))); in TEST_P()
2048 EXPECT_TRUE(matches(code, functionDecl(hasName("foo::test")))); in TEST_P()
2049 EXPECT_TRUE(matches(code, functionDecl(hasName("::foo::test")))); in TEST_P()
2050 EXPECT_TRUE(notMatches(code, functionDecl(hasName("::test")))); in TEST_P()
2053 EXPECT_TRUE(matches(code, functionDecl(hasName("test")))); in TEST_P()
2054 EXPECT_TRUE(matches(code, functionDecl(hasName("foo::test")))); in TEST_P()
2055 EXPECT_TRUE(matches(code, functionDecl(hasName("::foo::test")))); in TEST_P()
2056 EXPECT_TRUE(notMatches(code, functionDecl(hasName("::test")))); in TEST_P()
2082 recordDecl(hasName("A"), isDefinition()); in TEST_P()
2087 varDecl(hasName("a"), isDefinition()); in TEST_P()
2098 cxxMethodDecl(hasName("a"), isDefinition()); in TEST_P()
2103 objcMethodDecl(hasName("a"), isDefinition()); in TEST_P()
2144 ObjCString, objcIvarRefExpr(hasDeclaration(namedDecl(hasName("x")))))); in TEST_P()
2146 ObjCString, objcIvarRefExpr(hasDeclaration(namedDecl(hasName("y")))))); in TEST_P()
2187 memberExpr(member(hasName("first"))))); in TEST_P()
2199 memberExpr(member(hasName("first"))))); in TEST_P()
2211 memberExpr(member(hasName("first"))))); in TEST_P()
2225 fieldDecl(isBitField(), hasName("a")))); in TEST_P()
2227 fieldDecl(isBitField(), hasName("b")))); in TEST_P()
2229 fieldDecl(isBitField(), hasBitWidth(2), hasName("a")))); in TEST_P()
2240 hasName("a")))); in TEST_P()
2243 fieldDecl(hasInClassInitializer(anything()), hasName("b")))); in TEST_P()
2252 matches("struct A { int i; };", fieldDecl(isPublic(), hasName("i")))); in TEST_P()
2254 fieldDecl(isProtected(), hasName("i")))); in TEST_P()
2256 notMatches("struct A { int i; };", fieldDecl(isPrivate(), hasName("i")))); in TEST_P()
2259 notMatches("class A { int i; };", fieldDecl(isPublic(), hasName("i")))); in TEST_P()
2261 fieldDecl(isProtected(), hasName("i")))); in TEST_P()
2263 matches("class A { int i; };", fieldDecl(isPrivate(), hasName("i")))); in TEST_P()
2266 fieldDecl(isPublic(), hasName("i")))); in TEST_P()
2268 fieldDecl(isProtected(), hasName("i")))); in TEST_P()
2270 fieldDecl(isPrivate(), hasName("i")))); in TEST_P()
2273 EXPECT_TRUE(notMatches("int i;", varDecl(isPublic(), hasName("i")))); in TEST_P()
2274 EXPECT_TRUE(notMatches("int i;", varDecl(isProtected(), hasName("i")))); in TEST_P()
2275 EXPECT_TRUE(notMatches("int i;", varDecl(isPrivate(), hasName("i")))); in TEST_P()
2330 memberExpr(hasObjectExpression(hasType(recordDecl(hasName("X"))))))); in TEST_P()
2336 memberExpr(hasObjectExpression(hasType(recordDecl(hasName("X"))))))); in TEST_P()
2339 hasType(pointsTo(recordDecl(hasName("X")))))))); in TEST_P()
2350 declRefExpr(to(namedDecl(hasName("t")))))))); in TEST_P()
2354 declRefExpr(to(namedDecl(hasName("t")))))))); in TEST_P()
2364 memberExpr(hasObjectExpression(hasType(recordDecl(hasName("X"))))))); in TEST_P()
2376 hasType(recordDecl(hasName("X"))))))); in TEST_P()
2379 declRefExpr(to(namedDecl(hasName("t")))))))); in TEST_P()
2389 hasType(pointsTo(recordDecl(hasName("S")))))))); in TEST_P()
2392 hasType(pointsTo(recordDecl(hasName("S")))))))); in TEST_P()
2400 EXPECT_TRUE(notMatches("class X { void m(); };", fieldDecl(hasName("m")))); in TEST_P()
2401 EXPECT_TRUE(notMatches("class X { class m {}; };", fieldDecl(hasName("m")))); in TEST_P()
2402 EXPECT_TRUE(notMatches("class X { enum { m }; };", fieldDecl(hasName("m")))); in TEST_P()
2403 EXPECT_TRUE(notMatches("class X { enum m {}; };", fieldDecl(hasName("m")))); in TEST_P()
2407 EXPECT_TRUE(matches("struct X { int m; };", fieldDecl(hasName("m")))); in TEST_P()
2454 recordDecl(eachOf(has(fieldDecl(hasName("a")).bind("v")), in TEST_P()
2455 has(fieldDecl(hasName("b")).bind("v")))), in TEST_P()
2462 recordDecl(eachOf(has(fieldDecl(hasName("a")).bind("v")), in TEST_P()
2463 has(fieldDecl(hasName("b")).bind("v")))), in TEST_P()
2467 recordDecl(eachOf(has(fieldDecl(hasName("a")).bind("v")), in TEST_P()
2468 has(fieldDecl(hasName("b")).bind("v")))), in TEST_P()
2472 recordDecl(eachOf(has(fieldDecl(hasName("a")).bind("v")), in TEST_P()
2473 has(fieldDecl(hasName("b")).bind("v")))))); in TEST_P()
2479 recordDecl(optionally(has(fieldDecl(hasName("c")).bind("c")))), in TEST_P()
2487 optionally(has(fieldDecl(hasName("c")).bind("v")))); in TEST_P()
2499 recordDecl(optionally(has(fieldDecl(hasName("a")).bind("v")))), in TEST_P()
2514 cxxRecordDecl(hasName("::X"), isTemplateInstantiation()))); in TEST_P()
2520 hasDescendant(fieldDecl(hasType(recordDecl(hasName("A")))))))); in TEST_P()
2531 functionDecl(hasParameter(0, hasType(recordDecl(hasName("A")))), in TEST_P()
2545 hasType(recordDecl(hasName("A")))))))); in TEST_P()
2553 unless(hasDescendant(varDecl(hasName("t"))))))); in TEST_P()
2566 cxxRecordDecl(hasName("::X"), isTemplateInstantiation()))); in TEST_P()
2582 cxxRecordDecl(hasName("::X::Y"), isTemplateInstantiation()))); in TEST_P()
2601 cxxRecordDecl(hasName("::X<A>::Y"), unless(isTemplateInstantiation())))); in TEST_P()
2614 cxxRecordDecl(hasName("::X"), isTemplateInstantiation()))); in TEST_P()
3041 cxxRecordDecl(hasName("vector"), isInStdNamespace()))); in TEST_P()
3046 cxxRecordDecl(hasName("vector"), isInStdNamespace()))); in TEST_P()
3059 cxxRecordDecl(hasName("vector"), isInStdNamespace()))); in TEST_P()
3071 cxxRecordDecl(hasName("path"), isInStdNamespace()))); in TEST_P()
3084 cxxRecordDecl(hasName("path"), in TEST_P()
3085 hasAncestor(namespaceDecl(hasName("filesystem"), in TEST_P()
3102 "int i = 1;", varDecl(namedDecl(hasName("i")).bind("name"), in TEST_P()
3127 decl(allOf(recordDecl(hasName("::X::Y")).bind("record"), in TEST_P()
3131 decl(allOf(recordDecl(hasName("::X")).bind("record"), in TEST_P()
3144 has(fieldDecl(hasName("a"), hasType(type().bind("t")))), in TEST_P()
3145 has(fieldDecl(hasName("b"), hasType(type(equalsBoundNode("t")))))))); in TEST_P()
3150 has(fieldDecl(hasName("a"), hasType(type().bind("t")))), in TEST_P()
3151 has(fieldDecl(hasName("b"), hasType(type(equalsBoundNode("t")))))))); in TEST_P()
3184 hasName("f"), forEachDescendant(varDecl().bind("d")), in TEST_P()
3197 callee(cxxMethodDecl(hasName("data"))), in TEST_P()
3199 varDecl(hasType(recordDecl(hasName("StringRef")))).bind("var")))), in TEST_P()
3201 callee(cxxMethodDecl(anyOf(hasName("size"), hasName("length")))), in TEST_P()
3213 callee(cxxMethodDecl(hasName("data"))), in TEST_P()
3215 varDecl(hasType(recordDecl(hasName("StringRef")))).bind("var")))), in TEST_P()
3217 callee(cxxMethodDecl(anyOf(hasName("size"), hasName("length")))), in TEST_P()
3265 namedDecl(hasName("a"), hasExternalFormalLinkage()))); in TEST_P()
3267 namedDecl(hasName("a"), hasExternalFormalLinkage()))); in TEST_P()
3269 namedDecl(hasName("a"), hasExternalFormalLinkage()))); in TEST_P()
3271 namedDecl(hasName("a"), hasExternalFormalLinkage()))); in TEST_P()
3280 namedDecl(hasName("a"), hasExternalFormalLinkage()))); in TEST_P()
3789 cxxRecordDecl(hasName("ExpectedMatch"), in TEST_P()
3790 hasAnyBase(hasType(cxxRecordDecl(hasName("Base"))))))); in TEST_P()
3801 cxxRecordDecl(hasName("ExpectedMatch"), in TEST_P()
3802 hasAnyBase(hasType(cxxRecordDecl(hasName("Base"))))))); in TEST_P()
3948 cxxRecordDecl(hasName("Derived"), hasAnyBase(isVirtual())))); in TEST_P()
3970 cxxRecordDecl(hasName("Derived"), in TEST_P()
3971 hasDirectBase(hasType(cxxRecordDecl(hasName("Base"))))))); in TEST_P()
3981 cxxRecordDecl(hasName("Derived"), in TEST_P()
3982 hasDirectBase(hasType(cxxRecordDecl(hasName("Base"))))))); in TEST_P()
3985 cxxRecordDecl(hasName("Derived"), in TEST_P()
3986 hasDirectBase(hasType(cxxRecordDecl(hasName("Base2"))))))); in TEST_P()
3995 matches(Indirect, cxxRecordDecl(hasName("Derived"), in TEST_P()
3997 hasName("Intermediate"))))))); in TEST_P()
4000 cxxRecordDecl(hasName("Derived"), in TEST_P()
4001 hasDirectBase(hasType(cxxRecordDecl(hasName("Base"))))))); in TEST_P()