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

2023-09-11 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. Oh, I shouldn't have so much green in the status, whoops! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135341/new/ https://reviews.llvm.org/D135341 ___ cfe-commits mailing list cfe

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

2023-09-11 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D135341#4643712 , @erichkeane wrote: > Is the changes to cxx_status.html still relevant/current? Yeah. > Also, did we ever figure out what GCC did for a builtin here? Do they have > one yet? If not, have we encouraged them t

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

2023-09-11 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. Is the changes to cxx_status.html still relevant/current? Also, did we ever figure out what GCC did for a builtin here? Do they have one yet? If not, have we encouraged them to implement this one? If so, DID they implement this one? Repository: rG LLVM Github

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

2023-09-11 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb updated this revision to Diff 556488. cjdb added a comment. responds to feedback: - removes diagnostic - adds documentation Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135341/new/ https://reviews.llvm.org/D135341 Files: clang/docs/Langua

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

2023-09-11 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D135341#4126101 , @erichkeane wrote: > On the fence about the diagnostic at all, but definitely should not be doing > string magic to make it quoted. Otherwise this is a LGTM. Whoops, missed this comment. I'll be addressing yo

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

2023-02-14 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. On the fence about the diagnostic at all, but definitely should not be doing string magic to make it quoted. Otherwise this is a LGTM. Comment at: clang/lib/Sema/SemaExprCXX.cpp:5620 +std::string Spelling = "'" + std::string(getTraitSpelling(BT

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

2023-02-10 Thread Louis Dionne via Phabricator via cfe-commits
ldionne added a comment. In D135341#4111884 , @cjdb wrote: > In D135341#4111673 , @ldionne wrote: > >> I've been looking at implementing `reference_constructs_from_temporary` & >> friends and this would be sweet

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

2023-02-07 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D135341#4111673 , @ldionne wrote: > I've been looking at implementing `reference_constructs_from_temporary` & > friends and this would be sweet to have. Is this blocked on something > specific? This trait should be ready to go,

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

2023-02-07 Thread Louis Dionne via Phabricator via cfe-commits
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_fo

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

2022-10-11 Thread Roy Jacobson via Phabricator via cfe-commits
royjacobson added inline comments. Comment at: clang/docs/LanguageExtensions.rst:1476 is false. Note this trait will also return false when the initialization of ``T`` from ``U`` is ill-formed. +* ``__reference_constructs_from_temporary(T, U)`` (C++) royjac

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

2022-10-10 Thread Roy Jacobson via Phabricator via cfe-commits
royjacobson added inline comments. Comment at: clang/docs/LanguageExtensions.rst:1476 is false. Note this trait will also return false when the initialization of ``T`` from ``U`` is ill-formed. +* ``__reference_constructs_from_temporary(T, U)`` (C++) We sho

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

2022-10-10 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added inline comments. 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">; } erichkeane wrote: > I don't think we should dia

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

2022-10-10 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added inline comments. 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">; } I don't think we should diagnose this for

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

2022-10-08 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb updated this revision to Diff 466318. cjdb retitled this revision from "[clang] adds `__reference_constructs_from_temporary` and `__reference_converts_from_temporary`" to "[clang] adds `__reference_constructs_from_temporary`". cjdb added a comment. discards work on `__reference_converts_fr

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

2022-10-07 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb updated this revision to Diff 466088. cjdb added a comment. Gets `__reference_constructs_from_temporary` correct. Still WIP for the latter. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135341/new/ https://reviews.llvm.org/D135341 Files: cl

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

2022-10-06 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb added a comment. In D135341#3841126 , @ldionne wrote: > Interesting, I actually wasn't even aware of that C++23 feature in the > library. FWIW, libc++ will be more than happy to use that builtin instead of > trying to figure it out inside the libra

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

2022-10-06 Thread Louis Dionne via Phabricator via cfe-commits
ldionne added a comment. Interesting, I actually wasn't even aware of that C++23 feature in the library. FWIW, libc++ will be more than happy to use that builtin instead of trying to figure it out inside the library (if that's even possible)! We'll have to check whether GCC implements it, but h

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

2022-10-06 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb planned changes to this revision. cjdb added a comment. I learnt last night that this one is incredibly wrong and needs revising. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D135341/new/ https://reviews.llvm.org/D135341 _

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

2022-10-05 Thread Christopher Di Bella via Phabricator via cfe-commits
cjdb created this revision. cjdb added reviewers: aaron.ballman, shafik, erichkeane, tcanens. Herald added a project: All. cjdb requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This is information that the compiler already has, and should be