diff options
author | Aaron Ballman <aaron@aaronballman.com> | 2014-03-10 17:08:28 +0000 |
---|---|---|
committer | Aaron Ballman <aaron@aaronballman.com> | 2014-03-10 17:08:28 +0000 |
commit | be22bcb180714600926d5247ad9439f75cfc49db (patch) | |
tree | 4e134eb4edee82e21c48c0ed730c301aabace541 /clang/lib/CodeGen/CodeGenModule.cpp | |
parent | a7a94d10eaf571470868c65d232bf9c7c8621285 (diff) | |
download | bcm5719-llvm-be22bcb180714600926d5247ad9439f75cfc49db.tar.gz bcm5719-llvm-be22bcb180714600926d5247ad9439f75cfc49db.zip |
[C++11] Replacing DeclBase iterators specific_attr_begin() and specific_attr_end() with iterator_range specific_attrs(). Updating all of the usages of the iterators with range-based for loops.
llvm-svn: 203474
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
-rw-r--r-- | clang/lib/CodeGen/CodeGenModule.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp index c8dd8136fd2..4f040e27809 100644 --- a/clang/lib/CodeGen/CodeGenModule.cpp +++ b/clang/lib/CodeGen/CodeGenModule.cpp @@ -1051,10 +1051,8 @@ void CodeGenModule::AddGlobalAnnotations(const ValueDecl *D, llvm::GlobalValue *GV) { assert(D->hasAttr<AnnotateAttr>() && "no annotate attribute"); // Get the struct elements for these annotations. - for (specific_attr_iterator<AnnotateAttr> - ai = D->specific_attr_begin<AnnotateAttr>(), - ae = D->specific_attr_end<AnnotateAttr>(); ai != ae; ++ai) - Annotations.push_back(EmitAnnotateAttr(GV, *ai, D->getLocation())); + for (const auto *I : D->specific_attrs<AnnotateAttr>()) + Annotations.push_back(EmitAnnotateAttr(GV, I, D->getLocation())); } bool CodeGenModule::MayDeferGeneration(const ValueDecl *Global) { |