diff options
author | Eli Bendersky <eliben@chromium.org> | 2013-07-15 16:08:08 -0700 |
---|---|---|
committer | Eli Bendersky <eliben@chromium.org> | 2013-07-15 16:08:08 -0700 |
commit | e789858899a7b36caf11b371a97411a1582a482b (patch) | |
tree | e8c28b178b32010f73b477b3c65b5ff74437530c /lib/Tooling/Tooling.cpp | |
parent | 99a5501f5ae5b75017dfc386d4abf648234e85df (diff) | |
parent | 20c7d45a4da9f58ad805ad1d37f92fe7dc232ec8 (diff) |
Merge commit '20c7d45a4da9f58ad805ad1d37f92fe7dc232ec8'
Conflicts:
lib/CodeGen/ItaniumCXXABI.cpp
Diffstat (limited to 'lib/Tooling/Tooling.cpp')
-rw-r--r-- | lib/Tooling/Tooling.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/lib/Tooling/Tooling.cpp b/lib/Tooling/Tooling.cpp index a9e7b84808..52855f657f 100644 --- a/lib/Tooling/Tooling.cpp +++ b/lib/Tooling/Tooling.cpp @@ -22,6 +22,7 @@ #include "clang/Tooling/ArgumentsAdjusters.h" #include "clang/Tooling/CompilationDatabase.h" #include "llvm/ADT/STLExtras.h" +#include "llvm/Support/Debug.h" #include "llvm/Support/FileSystem.h" #include "llvm/Support/Host.h" #include "llvm/Support/raw_ostream.h" @@ -295,14 +296,19 @@ int ClangTool::run(FrontendActionFactory *ActionFactory) { ArgsAdjuster->Adjust(CompileCommands[I].second.CommandLine); assert(!CommandLine.empty()); CommandLine[0] = MainExecutable; - llvm::outs() << "Processing: " << File << ".\n"; + // FIXME: We need a callback mechanism for the tool writer to output a + // customized message for each file. + DEBUG({ + llvm::dbgs() << "Processing: " << File << ".\n"; + }); ToolInvocation Invocation(CommandLine, ActionFactory->create(), &Files); for (int I = 0, E = MappedFileContents.size(); I != E; ++I) { Invocation.mapVirtualFile(MappedFileContents[I].first, MappedFileContents[I].second); } if (!Invocation.run()) { - llvm::outs() << "Error while processing " << File << ".\n"; + // FIXME: Diagnostics should be used instead. + llvm::errs() << "Error while processing " << File << ".\n"; ProcessingFailed = true; } } |