From: Ted Kremenek Date: Mon, 6 Oct 2008 18:38:35 +0000 (+0000) Subject: Use Decl::decl_iterator instead of walking the ScopedDecl chain (which will soon... X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=04a72b77da736734c925d673834888a081f5ebc5;p=clang Use Decl::decl_iterator instead of walking the ScopedDecl chain (which will soon be removed). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@57190 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/AST/StmtDumper.cpp b/lib/AST/StmtDumper.cpp index a0af132bc4..dd92e84e9d 100644 --- a/lib/AST/StmtDumper.cpp +++ b/lib/AST/StmtDumper.cpp @@ -243,7 +243,9 @@ void StmtDumper::DumpDeclarator(Decl *D) { void StmtDumper::VisitDeclStmt(DeclStmt *Node) { DumpStmt(Node); fprintf(F,"\n"); - for (ScopedDecl *D = Node->getDecl(); D; D = D->getNextDeclarator()) { + for (DeclStmt::decl_iterator DI = Node->decl_begin(), DE = Node->decl_end(); + DI != DE; ++DI) { + ScopedDecl* D = *DI; ++IndentLevel; Indent(); fprintf(F, "%p ", (void*) D);