[PATCH] D109981: [Diagnostics] Don't drop a statically set NoWarningAsError flag during option processing

Duncan P. N. Exon Smith via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Dec 14 11:52:42 PST 2021


dexonsmith accepted this revision.
dexonsmith added a comment.
This revision is now accepted and ready to land.

LGTM.



================
Comment at: clang/test/Lexer/pragma-message.c:14
 #define STRING(x) STRING2(x)
-#pragma message(":O I'm a message! " STRING(__LINE__)) // expected-warning {{:O I'm a message! 13}}
-#pragma message ":O gcc accepts this! " STRING(__LINE__) // expected-warning {{:O gcc accepts this! 14}}
+#pragma message(":O I'm a message! " STRING(__LINE__)) // expected-warning {{:O I'm a message! 14}}
+#pragma message ":O gcc accepts this! " STRING(__LINE__) // expected-warning {{:O gcc accepts this! 15}}
----------------
Might be nice to delete a blank line above to avoid triggering all these line number changes. (That said, I don't really understand why they're listed at all, given that `-verify` handles line numbers... maybe we want to be sure the macros work in this context?)


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D109981/new/

https://reviews.llvm.org/D109981



More information about the cfe-commits mailing list