================
@@ -609,9 +609,25 @@ bool ConstStructBuilder::AppendBytes(CharUnits 
FieldOffsetInChars,
   return Builder.add(InitCst, StartOffset + FieldOffsetInChars, 
AllowOverwrite);
 }
 
-bool ConstStructBuilder::AppendBitField(
-    const FieldDecl *Field, uint64_t FieldOffset, llvm::ConstantInt *CI,
-    bool AllowOverwrite) {
+bool ConstStructBuilder::AppendBitField(const FieldDecl *Field,
+                                        uint64_t FieldOffset, llvm::Constant 
*C,
+                                        bool AllowOverwrite) {
+
+  llvm::ConstantInt *CI = dyn_cast<llvm::ConstantInt>(C);
+  if (!CI) {
+    // Constants for long _BitInt types are split into individual bytes.
----------------
rjmccall wrote:

```suggestion
    // Constants for _BitInt types are sometimes split into individual bytes.
```

Let's try to remember that this isn't *necessarily* a function of the size of 
the `_BitInt` type.

https://github.com/llvm/llvm-project/pull/91364
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to