diff options
author | Aaron Ballman <aaron@aaronballman.com> | 2014-03-07 19:56:05 +0000 |
---|---|---|
committer | Aaron Ballman <aaron@aaronballman.com> | 2014-03-07 19:56:05 +0000 |
commit | 629afaefe0cd1a583ccee54918b7b13f48bfe273 (patch) | |
tree | 9a236cdf36b4b96c8aad05ccdb63d8f40f9acd9c /clang/lib/AST/DeclBase.cpp | |
parent | d72a5f103da45e5abe10497308fce5aeb992cdc2 (diff) | |
download | bcm5719-llvm-629afaefe0cd1a583ccee54918b7b13f48bfe273.tar.gz bcm5719-llvm-629afaefe0cd1a583ccee54918b7b13f48bfe273.zip |
[C++11] Replacing DeclBase iterators decls_begin() and decls_end() with iterator_range decls(). The same is true for the noload versions of these APIs. Updating all of the usages of the iterators with range-based for loops.
llvm-svn: 203278
Diffstat (limited to 'clang/lib/AST/DeclBase.cpp')
-rw-r--r-- | clang/lib/AST/DeclBase.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/clang/lib/AST/DeclBase.cpp b/clang/lib/AST/DeclBase.cpp index 2c4df114755..711946ea009 100644 --- a/clang/lib/AST/DeclBase.cpp +++ b/clang/lib/AST/DeclBase.cpp @@ -1076,15 +1076,14 @@ ExternalASTSource::SetExternalVisibleDeclsForName(const DeclContext *DC, return List.getLookupResult(); } -DeclContext::decl_iterator DeclContext::noload_decls_begin() const { - return decl_iterator(FirstDecl); +DeclContext::decl_range DeclContext::noload_decls() const { + return decl_range(decl_iterator(FirstDecl), decl_iterator()); } -DeclContext::decl_iterator DeclContext::decls_begin() const { +DeclContext::decl_range DeclContext::decls() const { if (hasExternalLexicalStorage()) LoadLexicalDeclsFromExternalStorage(); - - return decl_iterator(FirstDecl); + return decl_range(decl_iterator(FirstDecl), decl_iterator()); } bool DeclContext::decls_empty() const { |