[clang] [clang] Allow -Wno-error=X to downgrade -pedantic-errors diagnostics to warnings (PR #184756)
Harald van Dijk via cfe-commits
cfe-commits at lists.llvm.org
Thu Mar 5 01:24:14 PST 2026
https://github.com/hvdijk approved this pull request.
Thanks! I'm seeing one other thing testing this that I don't think is caused by this PR, but is caused by the same bit of code. Will leave it to you whether it makes sense to address at the same time or leave it as it is:
With `gcc -pedantic-errors -Wlong-long`, use of `long long` is an error.
With `clang -pedantic-errors -Wlong-long`, use of `long long` is a warning.
I think the GCC behaviour makes sense: `-Wlong-long` only specifies that the diagnostic is to be enabled, it does not specify its severity and therefore should not override `-pedantic-errors`.
If you'd rather not change that right now, then this PR looks good to me.
https://github.com/llvm/llvm-project/pull/184756
More information about the cfe-commits
mailing list