Searched refs:ClassX (Results 1 – 3 of 3) sorted by relevance
/external/clang/unittests/ASTMatchers/ |
D | ASTMatchersNodeTest.cpp | 91 DeclarationMatcher ClassX = recordDecl(recordDecl(hasName("X"))); in TEST() local 92 EXPECT_TRUE(matches("class X;", ClassX)); in TEST() 93 EXPECT_TRUE(matches("class X {};", ClassX)); in TEST() 94 EXPECT_TRUE(matches("template<class T> class X {};", ClassX)); in TEST() 95 EXPECT_TRUE(notMatches("", ClassX)); in TEST() 119 DeclarationMatcher ClassX = classTemplateDecl(hasName("X")); in TEST() local 120 EXPECT_TRUE(notMatches("class X;", ClassX)); in TEST() 121 EXPECT_TRUE(notMatches("class X {};", ClassX)); in TEST() 125 DeclarationMatcher ClassX = classTemplateDecl(hasName("X")); in TEST() local 126 EXPECT_TRUE(matches("template<typename T> class X {};", ClassX)); in TEST() [all …]
|
D | ASTMatchersTraversalTest.cpp | 245 TypeMatcher ClassX = hasDeclaration(recordDecl(hasName("X"))); in TEST() local 247 matches("class X {}; void y(X &x) { x; }", expr(hasType(ClassX)))); in TEST() 250 expr(hasType(ClassX)))); in TEST() 253 expr(hasType(pointsTo(ClassX))))); in TEST() 257 TypeMatcher ClassX = hasDeclaration(recordDecl(hasName("X"))); in TEST() local 259 matches("class X {}; void y() { X x; }", varDecl(hasType(ClassX)))); in TEST() 261 notMatches("class X {}; void y() { X *x; }", varDecl(hasType(ClassX)))); in TEST() 264 varDecl(hasType(pointsTo(ClassX))))); in TEST() 268 DeclarationMatcher ClassX = recordDecl(hasName("X")); in TEST() local 270 matches("class X {}; void y(X &x) { x; }", expr(hasType(ClassX)))); in TEST() [all …]
|
D | ASTMatchersNarrowingTest.cpp | 547 DeclarationMatcher ClassX = has(recordDecl(hasName("::X")).bind("x")); in TEST() local 550 … ClassX, llvm::make_unique<VerifyIdIsBoundTo<CXXRecordDecl>>("x"))); in TEST() 553 … ClassX, llvm::make_unique<VerifyIdIsBoundTo<CXXRecordDecl>>("other-id"))); in TEST() 590 DeclarationMatcher ClassX = recordDecl(hasName("X")).bind("x"); in TEST() local 594 recordDecl(hasName("A"), hasDescendant(ClassX)), in TEST() 595 recordDecl(hasName("B"), hasDescendant(ClassX)))), in TEST()
|