[PATCH] D13081: [clang-tidy] Implement FixitHints for identifier references in IdentifierNamingCheck
Beren Minor via cfe-commits
cfe-commits at lists.llvm.org
Sun Sep 27 02:25:51 PDT 2015
berenm marked 3 inline comments as done.
Comment at: clang-tidy/readability/IdentifierNamingCheck.cpp:141
@@ +140,3 @@
+ Finder->addMatcher(usingDecl().bind("using"), this);
+ Finder->addMatcher(declRefExpr().bind("declRef"), this);
+ Finder->addMatcher(cxxConstructorDecl().bind("classRef"), this);
I wasn't sure how system headers were handled, and I thought it was a waste of time to check identifiers in them. But as you say it could be useful, I rolled back the change.
>From what I've seen, clang-tidy will display the warnings from incorrect declaration names in system header files when using the `-system-headers` and `-header-filter=.*` flags, but will not offer fixes for the declaration or usages in user's code. I guess editing system headers isn't going to work fine?
For user headers, warnings and fixes are emitted when `-header-filter=.*` is used.
Without the flag, no warnings or fixes are emitted, which is expected.
More information about the cfe-commits