diff options
author | Justin Bogner <mail@justinbogner.com> | 2014-06-20 22:16:00 +0000 |
---|---|---|
committer | Justin Bogner <mail@justinbogner.com> | 2014-06-20 22:16:00 +0000 |
commit | a7c5ec1c87bda9a98af5a168933be2dd6c56503f (patch) | |
tree | a606f7c0cb9a81029145fbddca819a4d069a26fd /include/clang/Driver/Compilation.h | |
parent | 51d7c9b21080953aee7b04b0acd38f7702be8a94 (diff) |
Driver: Record that we're in crashdump and push flags to ConstructJob
It's more flexible and arguably better layering to set flags to modify
compiling for diagnostics in the CC1 job themselves, rather than
tweaking the driver flags and letting them propagate.
There is one visible change this causes: crash report files will now
get preprocessed names (.i and friends).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@211411 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Driver/Compilation.h')
-rw-r--r-- | include/clang/Driver/Compilation.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/clang/Driver/Compilation.h b/include/clang/Driver/Compilation.h index 3493e4f150..c1c0f4326d 100644 --- a/include/clang/Driver/Compilation.h +++ b/include/clang/Driver/Compilation.h @@ -69,6 +69,9 @@ class Compilation { /// Redirection for stdout, stderr, etc. const StringRef **Redirects; + /// Whether we're compiling for diagnostic purposes. + bool ForDiagnostics; + public: Compilation(const Driver &D, const ToolChain &DefaultToolChain, llvm::opt::InputArgList *Args, @@ -173,6 +176,9 @@ public: /// so compilation can be reexecuted to generate additional diagnostic /// information (e.g., preprocessed source(s)). void initCompilationForDiagnostics(); + + /// Return true if we're compiling for diagnostics. + bool isForDiagnostics() { return ForDiagnostics; } }; } // end namespace driver |