[clang] [clang][NFC] Remove class layout scissor (PR #89055)

Fangrui Song via cfe-commits cfe-commits at lists.llvm.org
Sat May 4 11:16:02 PDT 2024


================
@@ -950,18 +948,20 @@ void CGRecordLowering::calculateZeroInit() {
 }
 
 // Verify accumulateBitfields computed the correct storage representations.
-void CGRecordLowering::checkBitfieldClipping() const {
+void CGRecordLowering::checkBitfieldClipping(
+    bool IsNonVirtualBaseType LLVM_ATTRIBUTE_UNUSED) const {
----------------
MaskRay wrote:

The doc of LLVM_ATTRIBUTE_UNUSED doesn't suggest variable uses.

Since we use `-Wno-unused-parameter` and `IsNonVirtualBaseType` is used in !NDEBUG code paths, we can just use `(bool IsNonVirtualBaseType)`

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


More information about the cfe-commits mailing list