[cfe-commits] r47913 - /cfe/trunk/AST/CFG.cpp

Ted Kremenek kremenek at apple.com
Tue Mar 4 14:29:40 PST 2008


Author: kremenek
Date: Tue Mar  4 16:29:40 2008
New Revision: 47913

URL: http://llvm.org/viewvc/llvm-project?rev=47913&view=rev
Log:
CallExprs are now no longer block-level expressions in the CFG by construction.

Modified:
    cfe/trunk/AST/CFG.cpp

Modified: cfe/trunk/AST/CFG.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/AST/CFG.cpp?rev=47913&r1=47912&r2=47913&view=diff

==============================================================================
--- cfe/trunk/AST/CFG.cpp (original)
+++ cfe/trunk/AST/CFG.cpp Tue Mar  4 16:29:40 2008
@@ -120,7 +120,6 @@
   CFGBlock* WalkAST_VisitChildren(Stmt* S);
   CFGBlock* WalkAST_VisitDeclSubExprs(StmtIterator& I);
   CFGBlock* WalkAST_VisitStmtExpr(StmtExpr* S);
-  CFGBlock* WalkAST_VisitCallExpr(CallExpr* C);
   void FinishBlock(CFGBlock* B);
   
 };
@@ -318,9 +317,6 @@
       return Block;
     }
     
-    case Stmt::CallExprClass:
-      return WalkAST_VisitCallExpr(cast<CallExpr>(S));
-      
     case Stmt::StmtExprClass:
       return WalkAST_VisitStmtExpr(cast<StmtExpr>(S));
 
@@ -438,14 +434,6 @@
   return VisitCompoundStmt(S->getSubStmt());  
 }
 
-/// WalkAST_VisitCallExpr - Utility method to handle function calls that
-///  are nested in expressions.  The idea is that each function call should
-///  appear as a distinct statement in the CFGBlock.
-CFGBlock* CFGBuilder::WalkAST_VisitCallExpr(CallExpr* C) {
-  Block->appendStmt(C);
-  return WalkAST_VisitChildren(C);
-}
-
 /// VisitStmt - Handle statements with no branching control flow.
 CFGBlock* CFGBuilder::VisitStmt(Stmt* Statement) {
   // We cannot assume that we are in the middle of a basic block, since





More information about the cfe-commits mailing list