================
@@ -2886,6 +2886,49 @@ class CXXPseudoDestructorExpr : public Expr {
   }
 };
 
+/// Represents a C++26 __builtin_type_order(T, U) expression. Used to implement
+/// std::type_order.
+class BuiltinTypeOrderExpr final : public Expr {
----------------
cor3ntin wrote:

I would *strongly* prefer we go that direction instead of adding a new node.
we have `TypeTraitReturnType` that can be used for that. That was introduced 
for StructuredBindingSize, so you can model on that.

We can extend that enum, and do the look up at that point. And we probably want 
to cache the type.
I'm not fan of returning a standard type from a builtin but if I recall this is 
the community preference, based on the fact `operator<=>` establishes precedent.




https://github.com/llvm/llvm-project/pull/216462
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to