================ @@ -263,6 +263,30 @@ template <bool Signed> class IntegralAP final { *R = IntegralAP(A.V.lshr(ShiftAmount)); } + // === Serialization support === + size_t bytesToSerialize() const { + // 1 byte for the BitWidth followed by N bytes for the actual APInt. + // FIXME: Is 1 byte enough? APInt::getBitWidth() returns an unsigned. ---------------- AaronBallman wrote:
I don't think one byte is sufficient if this will end up underpinning `_BitInt`. https://github.com/llvm/llvm-project/pull/79747 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits