diff options
Diffstat (limited to 'clang/lib/Frontend')
-rw-r--r-- | clang/lib/Frontend/AnalysisConsumer.cpp | 6 | ||||
-rw-r--r-- | clang/lib/Frontend/ResolveLocation.cpp | 2 | ||||
-rw-r--r-- | clang/lib/Frontend/RewriteBlocks.cpp | 5 | ||||
-rw-r--r-- | clang/lib/Frontend/RewriteObjC.cpp | 8 |
4 files changed, 13 insertions, 8 deletions
diff --git a/clang/lib/Frontend/AnalysisConsumer.cpp b/clang/lib/Frontend/AnalysisConsumer.cpp index d8fa141d8cb..2363ead9c19 100644 --- a/clang/lib/Frontend/AnalysisConsumer.cpp +++ b/clang/lib/Frontend/AnalysisConsumer.cpp @@ -479,14 +479,16 @@ static void ActionDisplayLiveVariables(AnalysisManager& mgr) { static void ActionCFGDump(AnalysisManager& mgr) { if (CFG* c = mgr.getCFG()) { mgr.DisplayFunction(); - c->dump(); + LangOptions LO; // FIXME! + c->dump(LO); } } static void ActionCFGView(AnalysisManager& mgr) { if (CFG* c = mgr.getCFG()) { mgr.DisplayFunction(); - c->viewCFG(); + LangOptions LO; // FIXME! + c->viewCFG(LO); } } diff --git a/clang/lib/Frontend/ResolveLocation.cpp b/clang/lib/Frontend/ResolveLocation.cpp index a5f0d1f1636..51827271f29 100644 --- a/clang/lib/Frontend/ResolveLocation.cpp +++ b/clang/lib/Frontend/ResolveLocation.cpp @@ -299,7 +299,7 @@ void LocResolverBase::print(Decl *D) { void LocResolverBase::print(Stmt *Node) { llvm::raw_ostream &OS = llvm::outs(); OS << "#### STMT ####\n"; - Node->printPretty(OS, Ctx); + Node->printPretty(OS, Ctx, 0, PrintingPolicy(Ctx.getLangOptions())); OS << " <"; Node->getLocStart().print(OS, Ctx.getSourceManager()); OS << " > - <"; diff --git a/clang/lib/Frontend/RewriteBlocks.cpp b/clang/lib/Frontend/RewriteBlocks.cpp index d20d5cd152c..28485326009 100644 --- a/clang/lib/Frontend/RewriteBlocks.cpp +++ b/clang/lib/Frontend/RewriteBlocks.cpp @@ -724,7 +724,8 @@ std::string RewriteBlocks::SynthesizeBlockCall(CallExpr *Exp) { BlockCall += "((struct __block_impl *)"; std::string closureExprBufStr; llvm::raw_string_ostream closureExprBuf(closureExprBufStr); - Exp->getCallee()->printPretty(closureExprBuf, *Context); + Exp->getCallee()->printPretty(closureExprBuf, *Context, 0, + PrintingPolicy(LangOpts)); BlockCall += closureExprBuf.str(); BlockCall += ")->FuncPtr)"; @@ -735,7 +736,7 @@ std::string RewriteBlocks::SynthesizeBlockCall(CallExpr *Exp) { E = Exp->arg_end(); I != E; ++I) { std::string syncExprBufS; llvm::raw_string_ostream Buf(syncExprBufS); - (*I)->printPretty(Buf, *Context); + (*I)->printPretty(Buf, *Context, 0, PrintingPolicy(LangOpts)); BlockCall += ", " + Buf.str(); } return BlockCall; diff --git a/clang/lib/Frontend/RewriteObjC.cpp b/clang/lib/Frontend/RewriteObjC.cpp index dce271070e0..6c1c10278a3 100644 --- a/clang/lib/Frontend/RewriteObjC.cpp +++ b/clang/lib/Frontend/RewriteObjC.cpp @@ -171,7 +171,7 @@ namespace { // Get the new text. std::string SStr; llvm::raw_string_ostream S(SStr); - New->printPretty(S, *Context); + New->printPretty(S, *Context, 0, PrintingPolicy(LangOpts)); const std::string &Str = S.str(); // If replacement succeeded or warning disabled return with no warning. @@ -1514,7 +1514,8 @@ Stmt *RewriteObjC::RewriteObjCSynchronizedStmt(ObjCAtSynchronizedStmt *S) { SourceLocation()); std::string syncExprBufS; llvm::raw_string_ostream syncExprBuf(syncExprBufS); - syncExpr->printPretty(syncExprBuf, *Context); + syncExpr->printPretty(syncExprBuf, *Context, 0, + PrintingPolicy(LangOpts)); buf += syncExprBuf.str(); buf += ");\n"; buf += " if (_rethrow) objc_exception_throw(_rethrow);\n"; @@ -2143,7 +2144,8 @@ Stmt *RewriteObjC::RewriteObjCStringLiteral(ObjCStringLiteral *Exp) { // The pretty printer for StringLiteral handles escape characters properly. std::string prettyBufS; llvm::raw_string_ostream prettyBuf(prettyBufS); - Exp->getString()->printPretty(prettyBuf, *Context); + Exp->getString()->printPretty(prettyBuf, *Context, 0, + PrintingPolicy(LangOpts)); Preamble += prettyBuf.str(); Preamble += ","; // The minus 2 removes the begin/end double quotes. |