aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Analysis/DIBuilder.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Analysis/DIBuilder.cpp')
-rw-r--r--lib/Analysis/DIBuilder.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/Analysis/DIBuilder.cpp b/lib/Analysis/DIBuilder.cpp
index 5e94d899b9..ee7ecd1b05 100644
--- a/lib/Analysis/DIBuilder.cpp
+++ b/lib/Analysis/DIBuilder.cpp
@@ -359,6 +359,22 @@ DIType DIBuilder::createObjCIVar(StringRef Name,
return DIType(MDNode::get(VMContext, Elts));
}
+/// createObjCProperty - Create debugging information entry for Objective-C
+/// property.
+DIObjCProperty DIBuilder::createObjCProperty(StringRef Name,
+ StringRef GetterName,
+ StringRef SetterName,
+ unsigned PropertyAttributes) {
+ Value *Elts[] = {
+ GetTagConstant(VMContext, dwarf::DW_TAG_APPLE_Property),
+ MDString::get(VMContext, Name),
+ MDString::get(VMContext, GetterName),
+ MDString::get(VMContext, SetterName),
+ ConstantInt::get(Type::getInt32Ty(VMContext), PropertyAttributes)
+ };
+ return DIObjCProperty(MDNode::get(VMContext, Elts));
+}
+
/// createClassType - Create debugging information entry for a class.
DIType DIBuilder::createClassType(DIDescriptor Context, StringRef Name,
DIFile File, unsigned LineNumber,