Page MenuHomePhabricator

[clang-tidy] Exempt _MSVC_EXECUTION_CHARACTER_SET from cppcoreguidelines-macro-usage
Needs ReviewPublic

Authored by zero9178 on Thu, Nov 25, 4:09 AM.



In I am trying to add an unconditional define to the MSVC cc1 driver which sadly then leads to a test failure in cppcoreguidelines-macro-usage-command-line-macros.cpp with MSVC builds.

The solution is a bit hacky IMO, but there seems to already be a similar workaround for __GCC_HAVE_DWARF2_CFI_ASM. I don't know of any way to differentiate between defines passed on the CLI by users, and ones set by the driver, so this will have to do for now.

Diff Detail

Event Timeline

zero9178 created this revision.Thu, Nov 25, 4:09 AM
zero9178 requested review of this revision.Thu, Nov 25, 4:09 AM
Herald added a project: Restricted Project. · View Herald TranscriptThu, Nov 25, 4:09 AM
Herald added a subscriber: cfe-commits. · View Herald Transcript
lebedev.ri resigned from this revision.Fri, Nov 26, 2:03 AM
lebedev.ri added inline comments.

Can that macro be defined elsewhere so this check fires instead of having to special-case the macro here?