summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaLookup.cpp
diff options
context:
space:
mode:
authorAaron Ballman <aaron@aaronballman.com>2014-03-06 23:45:36 +0000
committerAaron Ballman <aaron@aaronballman.com>2014-03-06 23:45:36 +0000
commit86c9390673f4be9a4064b7f3aa3a25636465758c (patch)
tree41f242a1d9e359fc2c87cf3a462faa7170dabab7 /clang/lib/Sema/SemaLookup.cpp
parent0e4b605e475690f8899c8a8a45e25b24138d2b82 (diff)
downloadbcm5719-llvm-86c9390673f4be9a4064b7f3aa3a25636465758c.tar.gz
bcm5719-llvm-86c9390673f4be9a4064b7f3aa3a25636465758c.zip
[C++11] Replacing iterators redecls_begin() and redecls_end() with iterator_range redecls(). Updating all of the usages of the iterators with range-based for loops, which allows the begin/end forms to be removed entirely.
llvm-svn: 203179
Diffstat (limited to 'clang/lib/Sema/SemaLookup.cpp')
-rw-r--r--clang/lib/Sema/SemaLookup.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/clang/lib/Sema/SemaLookup.cpp b/clang/lib/Sema/SemaLookup.cpp
index dfd078f5de4..059bc1cae73 100644
--- a/clang/lib/Sema/SemaLookup.cpp
+++ b/clang/lib/Sema/SemaLookup.cpp
@@ -1269,9 +1269,8 @@ bool LookupResult::isVisibleSlow(Sema &SemaRef, NamedDecl *D) {
static NamedDecl *findAcceptableDecl(Sema &SemaRef, NamedDecl *D) {
assert(!LookupResult::isVisible(SemaRef, D) && "not in slow case");
- for (Decl::redecl_iterator RD = D->redecls_begin(), RDEnd = D->redecls_end();
- RD != RDEnd; ++RD) {
- if (NamedDecl *ND = dyn_cast<NamedDecl>(*RD)) {
+ for (auto RD : D->redecls()) {
+ if (auto ND = dyn_cast<NamedDecl>(RD)) {
if (LookupResult::isVisible(SemaRef, ND))
return ND;
}
OpenPOWER on IntegriCloud