[PATCH] D135341: [clang] adds `__reference_constructs_from_temporary`

Louis Dionne via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Feb 7 17:24:52 PST 2023


ldionne added a comment.

I've been looking at implementing `reference_constructs_from_temporary` & friends and this would be sweet to have. Is this blocked on something specific?



================
Comment at: clang/include/clang/Basic/DiagnosticCommonKinds.td:397
+def err_reserved_identifier_for_future_use : Error<
+  "%0 is a compiler-reserved identifier for a future feature">;
 }
----------------
cjdb wrote:
> erichkeane wrote:
> > I don't think we should diagnose this for individual identifiers, I don't think this adds much value, and the identifier is already reserved for implementation use.  This implies we are going to diagnose ALL future reserved things, which we have no intention of doing.
> The motivation for this error is to ensure that standard library implementations don't take this name (`__remove_cvref` and `__is_null_pointer` had to get names that weren't a 1:1 mapping to their library counterparts as a result).
Oh, just ask and we can rename ours! What do you want us to rename?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D135341



More information about the cfe-commits mailing list