[PATCH] D120244: [clang][sema] Enable first-class bool support for C2x

Aaron Ballman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu May 26 11:12:34 PDT 2022


aaron.ballman added a comment.

In D120244#3540598 <https://reviews.llvm.org/D120244#3540598>, @aaron.ballman wrote:

> We could maybe extend `#pragma clang deprecate` to deprecate inclusion of the current file so that it acts sort of like a `[[deprecated]]` attribute that triggers on inclusion using typical diagnostics instead of `#warning`.

The tricky part to this is the pragma would effectively have to work like "diagnose on exit from this file when popping the lexing stack" because the header marks itself as being deprecated, so the compiler wouldn't KNOW to warn on the inclusion of the file (since it won't have seen the pragma by that point). It might be tricky to get the correct location for the diagnostic.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D120244



More information about the cfe-commits mailing list