[PATCH] D143301: [flang] Handle unsupported warning flags
Ethan Luis McDonough via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Feb 17 15:20:22 PST 2023
elmcdonough added a comment.
In D143301#4135301 <https://reviews.llvm.org/D143301#4135301>, @awarzynski wrote:
> @elmcdonough , let me rephrase this (should've been clearer before, sorry):
>
>> One thing that's not clear to me - how come "-Wextra" is not treated as an error and "-Wblah" is?
>
> Where's the logic that makes sure that `-Wextra` (and other flags that you redefine here) is reported as unused? That's not clear from this definition:
>
> multiclass FlangIgnoredDiagOpt<string name> {
> def unsupported_warning_w#NAME : Flag<["-", "--"], "W"#name>, Group<flang_ignored_w_Group>;
> }
>
> In particular, I don't see anything that would check whether a particular option is in this group: `flang_ignored_w_Group`.
I think I understand now. I initially didn't add any manual handling to the PR because I found that defining the options but leaving them as `Ignored` caused an "argument unused during compilation" whenever they were used in my local tests. This revision should give an explicit warning about the warning options not being supported.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D143301/new/
https://reviews.llvm.org/D143301
More information about the cfe-commits
mailing list