diff options
Diffstat (limited to 'include/clang/AST/RecursiveASTVisitor.h')
-rw-r--r-- | include/clang/AST/RecursiveASTVisitor.h | 24 |
1 files changed, 18 insertions, 6 deletions
diff --git a/include/clang/AST/RecursiveASTVisitor.h b/include/clang/AST/RecursiveASTVisitor.h index 95d7730..b118503 100644 --- a/include/clang/AST/RecursiveASTVisitor.h +++ b/include/clang/AST/RecursiveASTVisitor.h @@ -1881,8 +1881,8 @@ DEF_TRAVERSE_DECL(ParmVarDecl, { bool RecursiveASTVisitor<Derived>::Traverse##STMT(STMT *S) { \ TRY_TO(WalkUpFrom##STMT(S)); \ { CODE; } \ - for (Stmt::child_range range = S->children(); range; ++range) { \ - TRY_TO(TraverseStmt(*range)); \ + for (Stmt *SubStmt : S->children()) { \ + TRY_TO(TraverseStmt(SubStmt)); \ } \ return true; \ } @@ -2038,15 +2038,15 @@ bool RecursiveASTVisitor<Derived>::TraverseInitListExpr(InitListExpr *S) { if (Syn) { TRY_TO(WalkUpFromInitListExpr(Syn)); // All we need are the default actions. FIXME: use a helper function. - for (Stmt::child_range range = Syn->children(); range; ++range) { - TRY_TO(TraverseStmt(*range)); + for (Stmt *SubStmt : Syn->children()) { + TRY_TO(TraverseStmt(SubStmt)); } } InitListExpr *Sem = S->isSemanticForm() ? S : S->getSemanticForm(); if (Sem) { TRY_TO(WalkUpFromInitListExpr(Sem)); - for (Stmt::child_range range = Sem->children(); range; ++range) { - TRY_TO(TraverseStmt(*range)); + for (Stmt *SubStmt : Sem->children()) { + TRY_TO(TraverseStmt(SubStmt)); } } return true; @@ -2391,6 +2391,12 @@ DEF_TRAVERSE_STMT(OMPTaskwaitDirective, DEF_TRAVERSE_STMT(OMPTaskgroupDirective, { TRY_TO(TraverseOMPExecutableDirective(S)); }) +DEF_TRAVERSE_STMT(OMPCancellationPointDirective, + { TRY_TO(TraverseOMPExecutableDirective(S)); }) + +DEF_TRAVERSE_STMT(OMPCancelDirective, + { TRY_TO(TraverseOMPExecutableDirective(S)); }) + DEF_TRAVERSE_STMT(OMPFlushDirective, { TRY_TO(TraverseOMPExecutableDirective(S)); }) @@ -2655,6 +2661,12 @@ bool RecursiveASTVisitor<Derived>::VisitOMPFlushClause(OMPFlushClause *C) { return true; } +template <typename Derived> +bool RecursiveASTVisitor<Derived>::VisitOMPDependClause(OMPDependClause *C) { + TRY_TO(VisitOMPClauseList(C)); + return true; +} + // FIXME: look at the following tricky-seeming exprs to see if we // need to recurse on anything. These are ones that have methods // returning decls or qualtypes or nestednamespecifier -- though I'm |