AaronBallman wrote:

> Oh, just thought of one more thing: we probably want a c23_compat warning for 
> this (assuming the language is new in c23).

Good catch -- this is new in C23. C17 said: "Types other than pointer types 
whose referenced type is an object type shall not be restrict-qualified."

So there's two diagnostics needed: one is an `Extension` warning (so it fires 
in `-pedantic`) for use of an extension pre-C23, and the other is `Warning`, 
`DefaultIgnore` for code which is incompatible with standards before C23. (And 
test coverage for both).

https://github.com/llvm/llvm-project/pull/120896
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to