[clang] [clang]: implement std::meta::is_type (PR #211653)
Ambrose Leeb via cfe-commits
cfe-commits at lists.llvm.org
Fri Oct 16 08:46:46 PDT 2026
================
@@ -25,6 +25,24 @@
// precxx20-error at -3 {{does not have the constexpr builtin}}
// c-error at -4 {{does not have the constexpr builtin}}
+#if __has_builtin(__builtin_meta_is_type)
+#error has the builtin
+#else
+#error does not have the builtin
+#endif
+// cxx20-cxx26-error at -4 {{has the builtin}}
+// precxx20-error at -3 {{does not have the builtin}}
+// c-error at -4 {{does not have the builtin}}
----------------
Sirraide wrote:
Well, the metafunctions are only useful w/ reflection, which we’re almost certainly going to guard behind C++26, so yeah, I think we should just require C++26 (as well as `-freflection` currently) for all of them
https://github.com/llvm/llvm-project/pull/211653
More information about the cfe-commits
mailing list