[clang] [CodeGen] Replace of PointerType::get(Type) with opaque version (NFC) (PR #124771)

Mats Jun Larsen via cfe-commits cfe-commits at lists.llvm.org
Tue Jan 28 07:46:59 PST 2025


================
@@ -1097,31 +1097,10 @@ llvm::Type *CodeGenModule::getBlockDescriptorType() {
   if (BlockDescriptorType)
     return BlockDescriptorType;
 
-  llvm::Type *UnsignedLongTy =
-    getTypes().ConvertType(getContext().UnsignedLongTy);
-
-  // struct __block_descriptor {
-  //   unsigned long reserved;
-  //   unsigned long block_size;
-  //
-  //   // later, the following will be added
-  //
-  //   struct {
-  //     void (*copyHelper)();
-  //     void (*copyHelper)();
-  //   } helpers;                // !!! optional
-  //
-  //   const char *signature;   // the block signature
-  //   const char *layout;      // reserved
-  // };
----------------
junlarsen wrote:

I do feel a bit guilty about removing this comment. However, I'm not experienced enough to know if it's significant and something we'd like to keep?

Perhaps move it to the BlockDescriptorType decl?

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


More information about the cfe-commits mailing list