[PATCH] D53817: [clang-tidy] cppcoreguidelines-macro-usage: print macro names
Roman Lebedev via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Oct 29 09:20:15 PDT 2018
lebedev.ri added a comment.
In https://reviews.llvm.org/D53817#1278916, @JonasToth wrote:
> How does this patch change the behaviour for macros without location?
It doesn't.
> They will be diagnosed at the beginning of the TU?
> It is probably better to ignore these kind of macros, as there is no way around them (compile time configuration can only be done with macros?!) and therefore warnings for theses macros are false positives. Using `constexpr` constructs does not help either.
I agree that it might be good idea to add an *option* to not diagnose such macros.
But i think it is not the spirit of the check/rule to ignore them completely [by default],
because those macros are still horrible, and can affect all kinds of things,
just like the 'normal' macros.
Repository:
rCTE Clang Tools Extra
https://reviews.llvm.org/D53817
More information about the cfe-commits
mailing list