summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen
diff options
context:
space:
mode:
authorManman Ren <manman.ren@gmail.com>2016-01-26 18:05:23 +0000
committerManman Ren <manman.ren@gmail.com>2016-01-26 18:05:23 +0000
commita7a8b1f2c07aa87cbc37a5ded062b44250ef46dd (patch)
tree8b8f56ffb9df2fba563a556c945c0c7bbe8df3e1 /clang/lib/CodeGen
parent1eac5948dbf95abab5af7162dea7cf1d34585373 (diff)
downloadbcm5719-llvm-a7a8b1f2c07aa87cbc37a5ded062b44250ef46dd.tar.gz
bcm5719-llvm-a7a8b1f2c07aa87cbc37a5ded062b44250ef46dd.zip
Use instance_properties instead of properties. NFC.
All current properties are instance properties. This is the second patch in a series of patches to support class properties in addition to instance properties in objective-c. rdar://23891898 llvm-svn: 258824
Diffstat (limited to 'clang/lib/CodeGen')
-rw-r--r--clang/lib/CodeGen/CGDebugInfo.cpp4
-rw-r--r--clang/lib/CodeGen/CGObjCGNU.cpp2
-rw-r--r--clang/lib/CodeGen/CGObjCMac.cpp6
3 files changed, 6 insertions, 6 deletions
diff --git a/clang/lib/CodeGen/CGDebugInfo.cpp b/clang/lib/CodeGen/CGDebugInfo.cpp
index 675b5eb07c5..6d19e50e9f7 100644
--- a/clang/lib/CodeGen/CGDebugInfo.cpp
+++ b/clang/lib/CodeGen/CGDebugInfo.cpp
@@ -1822,11 +1822,11 @@ llvm::DIType *CGDebugInfo::CreateTypeDefinition(const ObjCInterfaceType *Ty,
{
llvm::SmallPtrSet<const IdentifierInfo*, 16> PropertySet;
for (const ObjCCategoryDecl *ClassExt : ID->known_extensions())
- for (auto *PD : ClassExt->properties()) {
+ for (auto *PD : ClassExt->instance_properties()) {
PropertySet.insert(PD->getIdentifier());
AddProperty(PD);
}
- for (const auto *PD : ID->properties()) {
+ for (const auto *PD : ID->instance_properties()) {
// Don't emit duplicate metadata for properties that were already in a
// class extension.
if (!PropertySet.insert(PD->getIdentifier()).second)
diff --git a/clang/lib/CodeGen/CGObjCGNU.cpp b/clang/lib/CodeGen/CGObjCGNU.cpp
index f0af3e924c0..d3722d64fc8 100644
--- a/clang/lib/CodeGen/CGObjCGNU.cpp
+++ b/clang/lib/CodeGen/CGObjCGNU.cpp
@@ -1849,7 +1849,7 @@ void CGObjCGNU::GenerateProtocol(const ObjCProtocolDecl *PD) {
// Add all of the property methods need adding to the method list and to the
// property metadata list.
- for (auto *property : PD->properties()) {
+ for (auto *property : PD->instance_properties()) {
std::vector<llvm::Constant*> Fields;
Fields.push_back(MakePropertyEncodingString(property, nullptr));
diff --git a/clang/lib/CodeGen/CGObjCMac.cpp b/clang/lib/CodeGen/CGObjCMac.cpp
index 079ec1531f8..035f90adfcf 100644
--- a/clang/lib/CodeGen/CGObjCMac.cpp
+++ b/clang/lib/CodeGen/CGObjCMac.cpp
@@ -2881,7 +2881,7 @@ PushProtocolProperties(llvm::SmallPtrSet<const IdentifierInfo*,16> &PropertySet,
const ObjCCommonTypesHelper &ObjCTypes) {
for (const auto *P : Proto->protocols())
PushProtocolProperties(PropertySet, Properties, Container, P, ObjCTypes);
- for (const auto *PD : Proto->properties()) {
+ for (const auto *PD : Proto->instance_properties()) {
if (!PropertySet.insert(PD->getIdentifier()).second)
continue;
llvm::Constant *Prop[] = {
@@ -2918,11 +2918,11 @@ llvm::Constant *CGObjCCommonMac::EmitPropertyList(Twine Name,
};
if (const ObjCInterfaceDecl *OID = dyn_cast<ObjCInterfaceDecl>(OCD))
for (const ObjCCategoryDecl *ClassExt : OID->known_extensions())
- for (auto *PD : ClassExt->properties()) {
+ for (auto *PD : ClassExt->instance_properties()) {
PropertySet.insert(PD->getIdentifier());
AddProperty(PD);
}
- for (const auto *PD : OCD->properties()) {
+ for (const auto *PD : OCD->instance_properties()) {
// Don't emit duplicate metadata for properties that were already in a
// class extension.
if (!PropertySet.insert(PD->getIdentifier()).second)
OpenPOWER on IntegriCloud