fgross created this revision.
HasDeclarationMatcher did not handle DeducedType, it always returned false for
deduced types.
So with code like this:
struct X{};
auto x = X{};
This did no longer match:
varDecl(hasType(recordDecl(hasName("X"
Because HasDeclarationMatcher didn't resol
klimek accepted this revision.
klimek added a comment.
This revision is now accepted and ready to land.
Thanks! LG after comment change.
Also, should we add some tests to clang-tidy? :)
Comment at: include/clang/ASTMatchers/ASTMatchersInternal.h:745
+
+// For deduced types
fgross updated this revision to Diff 109795.
fgross added a comment.
Changed comment, added some clang-tidy test cases.
https://reviews.llvm.org/D36308
Files:
include/clang/ASTMatchers/ASTMatchersInternal.h
test/clang-tidy/misc-use-after-move.cpp
test/clang-tidy/performance-inefficient-st
This revision was automatically updated to reflect the committed changes.
Closed by commit rL310095: [ASTMatcher] Add handling for DeducedType to
HasDeclarationMatcher (authored by fgross).
Changed prior to commit:
https://reviews.llvm.org/D36308?vs=109795&id=109796#toc
Repository:
rL LLVM