[clang] [clang] The `__reference_meows_from_temporary` builtins should SFINAE friendly when the 1st type is not a reference type (PR #206527)

Yihan Wang via cfe-commits cfe-commits at lists.llvm.org
Tue Jun 30 02:18:56 PDT 2026


yronglin wrote:

> IMO this is incorrect. https://eel.is/c++draft/type.traits clearly states that both types have to be complete.

> T is a reference type, and the initialization T t(VAL<U>); is well-formed

If the precondition `T is a reference type` is not satisfied, I think the compiler should not try to instantiation `T t(VAL<U>);`. This is what the PR want to fix.

https://github.com/llvm/llvm-project/pull/206527


More information about the cfe-commits mailing list