diff options
| author | Cong Liu <congliu@google.com> | 2016-06-24 09:38:03 +0000 |
|---|---|---|
| committer | Cong Liu <congliu@google.com> | 2016-06-24 09:38:03 +0000 |
| commit | 8a02efb143bf3cf1e3531906fc90bd432bca9d2e (patch) | |
| tree | 8a3ab87653c123c68128426356be45af1dd7fea8 /clang/docs/LibASTMatchersReference.html | |
| parent | 5f95c9af8d284c04476b03d1f77490e3cdd19e1a (diff) | |
| download | bcm5719-llvm-8a02efb143bf3cf1e3531906fc90bd432bca9d2e.tar.gz bcm5719-llvm-8a02efb143bf3cf1e3531906fc90bd432bca9d2e.zip | |
IgnoringImplicit matcher.
llvm-svn: 273659
Diffstat (limited to 'clang/docs/LibASTMatchersReference.html')
| -rw-r--r-- | clang/docs/LibASTMatchersReference.html | 25 |
1 files changed, 22 insertions, 3 deletions
diff --git a/clang/docs/LibASTMatchersReference.html b/clang/docs/LibASTMatchersReference.html index 3606367d2fd..30af7e326af 100644 --- a/clang/docs/LibASTMatchersReference.html +++ b/clang/docs/LibASTMatchersReference.html @@ -2347,7 +2347,7 @@ Given private: int c; }; fieldDecl(isPrivate()) - matches 'int c;' + matches 'int c;' </pre></td></tr> @@ -2361,7 +2361,7 @@ Given private: int c; }; fieldDecl(isProtected()) - matches 'int b;' + matches 'int b;' </pre></td></tr> @@ -2375,7 +2375,7 @@ Given private: int c; }; fieldDecl(isPublic()) - matches 'int a;' + matches 'int a;' </pre></td></tr> @@ -4455,6 +4455,25 @@ only match the declarations for b, c, and d. </pre></td></tr> +<tr><td>Matcher<<a href="http://clang.llvm.org/doxygen/classclang_1_1Expr.html">Expr</a>></td><td class="name" onclick="toggle('ignoringImplicit0')"><a name="ignoringImplicit0Anchor">ignoringImplicit</a></td><td>ast_matchers::Matcher<<a href="http://clang.llvm.org/doxygen/classclang_1_1Expr.html">Expr</a>> InnerMatcher</td></tr> +<tr><td colspan="4" class="doc" id="ignoringImplicit0"><pre>Matches expressions that match InnerMatcher after any implicit AST +nodes are stripped off. + +Parentheses and explicit casts are not discarded. +Given + class C {}; + C a = C(); + C b; + C c = b; +The matchers + varDecl(hasInitializer(ignoringImplicit(cxxConstructExpr()))) +would match the declarations for a, b, and c. +While + varDecl(hasInitializer(cxxConstructExpr())) +only match the declarations for b and c. +</pre></td></tr> + + <tr><td>Matcher<<a href="http://clang.llvm.org/doxygen/classclang_1_1Expr.html">Expr</a>></td><td class="name" onclick="toggle('ignoringParenCasts0')"><a name="ignoringParenCasts0Anchor">ignoringParenCasts</a></td><td>Matcher<<a href="http://clang.llvm.org/doxygen/classclang_1_1Expr.html">Expr</a>> InnerMatcher</td></tr> <tr><td colspan="4" class="doc" id="ignoringParenCasts0"><pre>Matches expressions that match InnerMatcher after parentheses and casts are stripped off. |

