[clang] [clang]: support std::meta::info for primitive types (PR #190356)

Nhat Nguyen via cfe-commits cfe-commits at lists.llvm.org
Thu Apr 9 16:08:56 PDT 2026


================
@@ -515,6 +515,10 @@ llvm::Type *CodeGenTypes::ConvertType(QualType T) {
       ResultType = llvm::PointerType::getUnqual(getLLVMContext());
       break;
 
+    case BuiltinType::MetaInfo:
+      ResultType = llvm::IntegerType::get(getLLVMContext(), 64);
+      break;
----------------
changkhothuychung wrote:

Yeah I agree. However, now we don't have support for consteval-only type yet, so this will crash the codegen test. 

```cpp
(void)(^^int); // expected-error {{cannot compile this scalar expression yet}}
```

Is issuing a diagnostics and then recovering gracefully an option here? 



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


More information about the cfe-commits mailing list