summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGObjCMac.cpp
diff options
context:
space:
mode:
authorAaron Ballman <aaron@aaronballman.com>2014-03-13 20:55:22 +0000
committerAaron Ballman <aaron@aaronballman.com>2014-03-13 20:55:22 +0000
commita9f49e394c8e25c1f6e0693e52a770125f01d7e1 (patch)
treeb0f7235edce127c97920a3c67e678a67cae36834 /clang/lib/CodeGen/CGObjCMac.cpp
parente937888e1c4eeafba7eab0359e00f5d28da93ecd (diff)
downloadbcm5719-llvm-a9f49e394c8e25c1f6e0693e52a770125f01d7e1.tar.gz
bcm5719-llvm-a9f49e394c8e25c1f6e0693e52a770125f01d7e1.zip
[C++11] Replacing ObjCInterfaceDecl iterators all_referenced_protocol_begin() and all_referenced_protocol_end() with iterator_range all_referenced_protocols(). Updating all of the usages of the iterators with range-based for loops.
llvm-svn: 203848
Diffstat (limited to 'clang/lib/CodeGen/CGObjCMac.cpp')
-rw-r--r--clang/lib/CodeGen/CGObjCMac.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/clang/lib/CodeGen/CGObjCMac.cpp b/clang/lib/CodeGen/CGObjCMac.cpp
index 98bdb16889d..e62eddd695a 100644
--- a/clang/lib/CodeGen/CGObjCMac.cpp
+++ b/clang/lib/CodeGen/CGObjCMac.cpp
@@ -2813,11 +2813,8 @@ llvm::Constant *CGObjCCommonMac::EmitPropertyList(Twine Name,
Prop));
}
if (const ObjCInterfaceDecl *OID = dyn_cast<ObjCInterfaceDecl>(OCD)) {
- for (ObjCInterfaceDecl::all_protocol_iterator
- P = OID->all_referenced_protocol_begin(),
- E = OID->all_referenced_protocol_end(); P != E; ++P)
- PushProtocolProperties(PropertySet, Properties, Container, (*P),
- ObjCTypes);
+ for (const auto *P : OID->all_referenced_protocols())
+ PushProtocolProperties(PropertySet, Properties, Container, P, ObjCTypes);
}
else if (const ObjCCategoryDecl *CD = dyn_cast<ObjCCategoryDecl>(OCD)) {
for (ObjCCategoryDecl::protocol_iterator P = CD->protocol_begin(),
OpenPOWER on IntegriCloud