summaryrefslogtreecommitdiffstats
path: root/clang/lib/AST/StmtProfile.cpp
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2011-02-13 04:07:26 +0000
committerJohn McCall <rjmccall@apple.com>2011-02-13 04:07:26 +0000
commit8322c3a19768bdc4f48dc7c206ed30035d9fa755 (patch)
treedd6e5f2da2678340e5dce3d2c765ef349c8f1b7e /clang/lib/AST/StmtProfile.cpp
parent4f23f2be15d9d1342687dd49190dca0457fc9c9c (diff)
downloadbcm5719-llvm-8322c3a19768bdc4f48dc7c206ed30035d9fa755.tar.gz
bcm5719-llvm-8322c3a19768bdc4f48dc7c206ed30035d9fa755.zip
Give some convenient idiomatic accessors to Stmt::child_range and
Stmt::const_child_range, then make a bunch of places use them instead of the individual iterator accessors. llvm-svn: 125450
Diffstat (limited to 'clang/lib/AST/StmtProfile.cpp')
-rw-r--r--clang/lib/AST/StmtProfile.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/clang/lib/AST/StmtProfile.cpp b/clang/lib/AST/StmtProfile.cpp
index 707cac4edfe..b96ffe8a48e 100644
--- a/clang/lib/AST/StmtProfile.cpp
+++ b/clang/lib/AST/StmtProfile.cpp
@@ -68,8 +68,7 @@ namespace {
void StmtProfiler::VisitStmt(Stmt *S) {
ID.AddInteger(S->getStmtClass());
- for (Stmt::child_iterator C = S->child_begin(), CEnd = S->child_end();
- C != CEnd; ++C)
+ for (Stmt::child_range C = S->children(); C; ++C)
Visit(*C);
}
OpenPOWER on IntegriCloud