From 26e1cda1f470e36fe7d4321570a671354e7ef784 Mon Sep 17 00:00:00 2001 From: "Duncan P. N. Exon Smith" Date: Mon, 13 Apr 2015 23:55:01 +0000 Subject: DebugInfo: Remove DIObjCProperty attribute accessors, NFC There's only one user of the various `DIObjCProperty::is*Property()` accessors -- `DwarfUnit::constructTypeDIE()` -- and it's just using the reverse logic to reconstruct the bitfield. Drop this API and simplify the only caller. llvm-svn: 234818 --- llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) (limited to 'llvm/lib/CodeGen/AsmPrinter') diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp b/llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp index f4c430ae705..26b993094c9 100644 --- a/llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp +++ b/llvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp @@ -1072,20 +1072,7 @@ void DwarfUnit::constructTypeDIE(DIE &Buffer, DICompositeType CTy) { StringRef SetterName = Property.getObjCPropertySetterName(); if (!SetterName.empty()) addString(ElemDie, dwarf::DW_AT_APPLE_property_setter, SetterName); - unsigned PropertyAttributes = 0; - if (Property.isReadOnlyObjCProperty()) - PropertyAttributes |= dwarf::DW_APPLE_PROPERTY_readonly; - if (Property.isReadWriteObjCProperty()) - PropertyAttributes |= dwarf::DW_APPLE_PROPERTY_readwrite; - if (Property.isAssignObjCProperty()) - PropertyAttributes |= dwarf::DW_APPLE_PROPERTY_assign; - if (Property.isRetainObjCProperty()) - PropertyAttributes |= dwarf::DW_APPLE_PROPERTY_retain; - if (Property.isCopyObjCProperty()) - PropertyAttributes |= dwarf::DW_APPLE_PROPERTY_copy; - if (Property.isNonAtomicObjCProperty()) - PropertyAttributes |= dwarf::DW_APPLE_PROPERTY_nonatomic; - if (PropertyAttributes) + if (unsigned PropertyAttributes = Property.getAttributes()) addUInt(ElemDie, dwarf::DW_AT_APPLE_property_attribute, None, PropertyAttributes); -- cgit v1.2.3