diff options
author | Stephen Kelly <steveire@gmail.com> | 2019-12-20 21:32:43 +0000 |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2019-12-20 21:33:31 +0000 |
commit | 0378f3a90341d990236c44f297b923a32b35fab1 (patch) | |
tree | 1b0c2637bbb113f0dca328972d760a8e18a43e56 /clang/unittests/ASTMatchers | |
parent | c431c407ebcbbb526f4af93a549fa5b260a9b193 (diff) | |
download | bcm5719-llvm-0378f3a90341d990236c44f297b923a32b35fab1.tar.gz bcm5719-llvm-0378f3a90341d990236c44f297b923a32b35fab1.zip |
Revert "Customize simplified dumping and matching of LambdaExpr"
This reverts commit 494b1318ca77927e919bbf9a61749a58553d738c.
Diffstat (limited to 'clang/unittests/ASTMatchers')
-rw-r--r-- | clang/unittests/ASTMatchers/ASTMatchersTraversalTest.cpp | 28 |
1 files changed, 0 insertions, 28 deletions
diff --git a/clang/unittests/ASTMatchers/ASTMatchersTraversalTest.cpp b/clang/unittests/ASTMatchers/ASTMatchersTraversalTest.cpp index b9075927d74..a21ed04b32d 100644 --- a/clang/unittests/ASTMatchers/ASTMatchersTraversalTest.cpp +++ b/clang/unittests/ASTMatchers/ASTMatchersTraversalTest.cpp @@ -1751,17 +1751,6 @@ B func12() { return c; } -void func13() { - int a = 0; - int c = 0; - - [a, b = c](int d) { int e = d; }; -} - -void func14() { - [] <typename TemplateType> (TemplateType t, TemplateType u) { int e = t + u; }; -} - )cpp"; EXPECT_TRUE(matches( @@ -1832,23 +1821,6 @@ void func14() { returnStmt(forFunction(functionDecl(hasName("func12"))), hasReturnValue( declRefExpr(to(varDecl(hasName("c"))))))))); - - EXPECT_TRUE(matches( - Code, - traverse( - ast_type_traits::TK_IgnoreUnlessSpelledInSource, - lambdaExpr(forFunction(functionDecl(hasName("func13"))), - has(compoundStmt(hasDescendant(varDecl(hasName("e"))))), - has(declRefExpr(to(varDecl(hasName("a"))))), - has(varDecl(hasName("b"), hasInitializer(declRefExpr(to( - varDecl(hasName("c"))))))), - has(parmVarDecl(hasName("d"))))))); - - EXPECT_TRUE(matches( - Code, traverse(ast_type_traits::TK_IgnoreUnlessSpelledInSource, - lambdaExpr( - forFunction(functionDecl(hasName("func14"))), - has(templateTypeParmDecl(hasName("TemplateType"))))))); } TEST(IgnoringImpCasts, MatchesImpCasts) { |