================
@@ -3959,6 +3959,14 @@ llvm::Constant 
*CodeGenFunction::EmitCheckTypeDescriptor(QualType T) {
   uint16_t TypeInfo = 0;
   bool IsBitInt = false;
 
+  // isIntegerType() never holds for scoped enums, and getAs<BitIntType> can't
+  // see through the EnumType node to a __BitInt underlying type even for
+  // unscoped enums.
+  QualType BackupT = T;
+  if (const EnumType *ET = T->getAs<EnumType>())
+    if (ET->getDecl()->isComplete())
----------------
zebullax wrote:

We could , but before our change an incomplete enum would not ICE, so it would 
be fairly hostile to users ? Incomplete now (as before) simply trickled down to 
`unknown` , which isnt awesome but at least consistent with previous state.

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

Reply via email to