diff --git a/clang/lib/CodeGen/CGDebugInfo.cpp b/clang/lib/CodeGen/CGDebugInfo.cpp index c937e8ec67ec..7d0c1ad8a55f 100644 --- a/clang/lib/CodeGen/CGDebugInfo.cpp +++ b/clang/lib/CodeGen/CGDebugInfo.cpp @@ -280,8 +280,10 @@ llvm::DIType CGDebugInfo::CreateType(const BlockPointerType *Ty, Elements = DebugFactory.GetOrCreateArray(EltTys.data(), EltTys.size()); EltTys.clear(); + unsigned Flags = llvm::DIType::FlagAppleBlock; + EltTy = DebugFactory.CreateCompositeType(Tag, Unit, "__block_descriptor", - DefUnit, 0, FieldOffset, 0, 0, 0, + DefUnit, 0, FieldOffset, 0, 0, Flags, llvm::DIType(), Elements); // Bit size, align and offset of the type. @@ -350,8 +352,6 @@ llvm::DIType CGDebugInfo::CreateType(const BlockPointerType *Ty, FieldOffset += FieldSize; Elements = DebugFactory.GetOrCreateArray(EltTys.data(), EltTys.size()); - unsigned Flags = llvm::DIType::FlagAppleBlock; - EltTy = DebugFactory.CreateCompositeType(Tag, Unit, "__block_literal_generic", DefUnit, 0, FieldOffset, 0, 0, Flags, llvm::DIType(), Elements);