This fixes https://llvm.org/bugs/show_bug.cgi?id=24835.
The patch might be slightly different after http://reviews.llvm.org/D13079 and http://reviews.llvm.org/D13081, but the idea is the same.
Differential D13090
[clang-tidy] IdentifierNamingCheck should only emit warnings when declaration or usage is outside of macros berenm on Sep 23 2015, 12:25 AM. Authored by
Details
This fixes https://llvm.org/bugs/show_bug.cgi?id=24835. The patch might be slightly different after http://reviews.llvm.org/D13079 and http://reviews.llvm.org/D13081, but the idea is the same.
Diff Detail Event TimelineComment Actions This will also disable all warnings for declaration / usages outside of the main file. It might be better to disable the warnings and fixes whenever a macro is involved (in the declaration or any usage), but at least keep the warning across files, even if we don't offer fixes. I think the most common use-case will be to have some declaration in a header file and usages in multiple source files, and in this case warnings are interesting. I'm assuming here that "main file" in clang tooling framework means the .cpp file from which the ast is built. |