This is an archive of the discontinued LLVM Phabricator instance.

[clang-cl] Ignore /Wv and /Wv:17 flags
ClosedPublic

Authored by thieta on Mar 23 2022, 1:55 AM.

Details

Summary

MSVC supports passing /Wv and /Wv:17 to ignore warnings added
since that version. Clang doesn't have a option like this - but
we can ignore this flag instead of error.

MSVC documentation: https://docs.microsoft.com/en-us/cpp/build/reference/compiler-option-warning-level

Diff Detail

Event Timeline

thieta created this revision.Mar 23 2022, 1:55 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 23 2022, 1:55 AM
thieta requested review of this revision.Mar 23 2022, 1:55 AM
Herald added a project: Restricted Project. · View Herald Transcript
Herald added a subscriber: sstefan1. · View Herald Transcript
thieta updated this revision to Diff 417533.Mar 23 2022, 1:59 AM

Added back removed blank line

clang/include/clang/Driver/Options.td
2498–2499

Do we mind removing these trailing whitespaces in the same commit? I can fix that - but they shouldn't be there anyway.

mstorsjo accepted this revision.Mar 23 2022, 2:11 AM

The patch itself seems sensible to me.

clang/include/clang/Driver/Options.td
2498–2499

I think it'd be fine to just push such a commit without taking it through review, marked as NFC (no functional changes). Or keep it here but split it out into a separate commit before pushing.

This revision is now accepted and ready to land.Mar 23 2022, 2:11 AM
thieta updated this revision to Diff 417537.Mar 23 2022, 2:22 AM

Split whitespace to it's own commit

thieta marked an inline comment as done.Mar 23 2022, 2:24 AM
hans accepted this revision.Mar 23 2022, 2:58 AM

Looks great, thanks!

This revision was automatically updated to reflect the committed changes.