forked from OSchip/llvm-project
Remove a dependency on Frontend headers in the Driver library. Also saves
building and passing arguments to cc1 layer when setting values to their defaults. llvm-svn: 103162
This commit is contained in:
parent
1a56a488ed
commit
a77a72734c
|
@ -81,8 +81,8 @@ public:
|
|||
VerifyDiagnostics = 0;
|
||||
BinaryOutput = 0;
|
||||
ErrorLimit = 0;
|
||||
TemplateBacktraceLimit = 0;
|
||||
MacroBacktraceLimit = 0;
|
||||
TemplateBacktraceLimit = DefaultTemplateBacktraceLimit;
|
||||
MacroBacktraceLimit = DefaultMacroBacktraceLimit;
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
@ -21,7 +21,6 @@
|
|||
#include "clang/Driver/Options.h"
|
||||
#include "clang/Driver/ToolChain.h"
|
||||
#include "clang/Driver/Util.h"
|
||||
#include "clang/Frontend/DiagnosticOptions.h"
|
||||
|
||||
#include "llvm/ADT/SmallString.h"
|
||||
#include "llvm/ADT/StringSwitch.h"
|
||||
|
@ -1083,20 +1082,16 @@ void Clang::ConstructJob(Compilation &C, const JobAction &JA,
|
|||
else
|
||||
CmdArgs.push_back("19");
|
||||
|
||||
CmdArgs.push_back("-fmacro-backtrace-limit");
|
||||
if (Arg *A = Args.getLastArg(options::OPT_fmacro_backtrace_limit_EQ))
|
||||
if (Arg *A = Args.getLastArg(options::OPT_fmacro_backtrace_limit_EQ)) {
|
||||
CmdArgs.push_back("-fmacro-backtrace-limit");
|
||||
CmdArgs.push_back(A->getValue(Args));
|
||||
else
|
||||
CmdArgs.push_back(Args.MakeArgString(
|
||||
llvm::Twine(DiagnosticOptions::DefaultMacroBacktraceLimit)));
|
||||
|
||||
CmdArgs.push_back("-ftemplate-backtrace-limit");
|
||||
if (Arg *A = Args.getLastArg(options::OPT_ftemplate_backtrace_limit_EQ))
|
||||
}
|
||||
|
||||
if (Arg *A = Args.getLastArg(options::OPT_ftemplate_backtrace_limit_EQ)) {
|
||||
CmdArgs.push_back("-ftemplate-backtrace-limit");
|
||||
CmdArgs.push_back(A->getValue(Args));
|
||||
else
|
||||
CmdArgs.push_back(Args.MakeArgString(
|
||||
llvm::Twine(DiagnosticOptions::DefaultTemplateBacktraceLimit)));
|
||||
|
||||
}
|
||||
|
||||
// Pass -fmessage-length=.
|
||||
CmdArgs.push_back("-fmessage-length");
|
||||
if (Arg *A = Args.getLastArg(options::OPT_fmessage_length_EQ)) {
|
||||
|
|
Loading…
Reference in New Issue