[clang] [clang] Implement the __builtin_type_order intrinsic for P2830R10 Constexpr Type Ordering (PR #216462)

Timm Baeder via cfe-commits cfe-commits at lists.llvm.org
Sun Aug 16 02:42:56 PDT 2026


================
@@ -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 {
+  friend class ASTStmtReader;
+
+  SourceLocation Loc;
+  SourceLocation RParenLoc;
+  TypeSourceInfo *Lhs;
+  TypeSourceInfo *Rhs;
----------------
tbaederr wrote:

These should be LHS and RHS, same for the getters in this class.

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


More information about the cfe-commits mailing list