mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-11-23 22:00:10 +00:00
[Clang][CGDebugInfo][ObjC] Mark objc bitfields with the DIFlagBitfield flag
Reviewed By: aprantl Differential Revision: https://reviews.llvm.org/D140195
This commit is contained in:
parent
1341780847
commit
1118ee04fc
@ -2930,6 +2930,9 @@ llvm::DIType *CGDebugInfo::CreateTypeDefinition(const ObjCInterfaceType *Ty,
|
|||||||
else if (Field->getAccessControl() == ObjCIvarDecl::Public)
|
else if (Field->getAccessControl() == ObjCIvarDecl::Public)
|
||||||
Flags = llvm::DINode::FlagPublic;
|
Flags = llvm::DINode::FlagPublic;
|
||||||
|
|
||||||
|
if (Field->isBitField())
|
||||||
|
Flags |= llvm::DINode::FlagBitField;
|
||||||
|
|
||||||
llvm::MDNode *PropertyNode = nullptr;
|
llvm::MDNode *PropertyNode = nullptr;
|
||||||
if (ObjCImplementationDecl *ImpD = ID->getImplementation()) {
|
if (ObjCImplementationDecl *ImpD = ID->getImplementation()) {
|
||||||
if (ObjCPropertyImplDecl *PImpD =
|
if (ObjCPropertyImplDecl *PImpD =
|
||||||
|
@ -30,15 +30,15 @@ __attribute((objc_root_class)) @interface NSObject {
|
|||||||
// CHECK-SAME: baseType: ![[UNSIGNED:[0-9]+]]
|
// CHECK-SAME: baseType: ![[UNSIGNED:[0-9]+]]
|
||||||
// CHECK-SAME: size: 9,
|
// CHECK-SAME: size: 9,
|
||||||
// CHECK-NOT: offset:
|
// CHECK-NOT: offset:
|
||||||
// CHECK-SAME: flags: DIFlagProtected
|
// CHECK-SAME: flags: DIFlagProtected | DIFlagBitField
|
||||||
// CHECK: ![[UNSIGNED]] = !DIBasicType(name: "unsigned int"
|
// CHECK: ![[UNSIGNED]] = !DIBasicType(name: "unsigned int"
|
||||||
// CHECK: !DIDerivedType(tag: DW_TAG_member, name: "flag_2"
|
// CHECK: !DIDerivedType(tag: DW_TAG_member, name: "flag_2"
|
||||||
// CHECK-SAME: line: 12
|
// CHECK-SAME: line: 12
|
||||||
// CHECK-SAME: baseType: ![[UNSIGNED]]
|
// CHECK-SAME: baseType: ![[UNSIGNED]]
|
||||||
// CHECK-SAME: size: 9, offset: 1,
|
// CHECK-SAME: size: 9, offset: 1,
|
||||||
// CHECK-SAME: flags: DIFlagProtected
|
// CHECK-SAME: flags: DIFlagProtected | DIFlagBitField
|
||||||
// CHECK: !DIDerivedType(tag: DW_TAG_member, name: "flag_3"
|
// CHECK: !DIDerivedType(tag: DW_TAG_member, name: "flag_3"
|
||||||
// CHECK-SAME: line: 14
|
// CHECK-SAME: line: 14
|
||||||
// CHECK-SAME: baseType: ![[UNSIGNED]]
|
// CHECK-SAME: baseType: ![[UNSIGNED]]
|
||||||
// CHECK-SAME: size: 9, offset: 3,
|
// CHECK-SAME: size: 9, offset: 3,
|
||||||
// CHECK-SAME: flags: DIFlagProtected
|
// CHECK-SAME: flags: DIFlagProtected | DIFlagBitField
|
||||||
|
Loading…
Reference in New Issue
Block a user