================
@@ -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 {
----------------
Tsche wrote:

Yeah, unfortunately the builtin trait infrastructure just allows us to return 
`bool` or `size_t`. I tried hacking it into TypeTraitExpr, but that was 
horrible. Ended up not reusing the type trait parsing either to make this a 
little less surprising/magic.

It's not the only builtin we handle this way. `__builtin_source_location` and 
`__builtin_bit_cast` are similar. 

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