aboutsummaryrefslogtreecommitdiff
path: root/lib/FrontendTool/ExecuteCompilerInvocation.cpp
diff options
context:
space:
mode:
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>2012-01-26 02:40:48 +0000
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>2012-01-26 02:40:48 +0000
commit61d679ab2831b161c857cf3f974312fbd4ef1efd (patch)
tree28dca5905a35f13993ff40bb855b1fee35af08a9 /lib/FrontendTool/ExecuteCompilerInvocation.cpp
parent7a776bec0232a5bf63b8d655194c18a201e5ee47 (diff)
Introduce 3 new fixit options:
-fixit-recompile applies fixits and recompiles the result -fixit-to-temporary applies fixits to temporary files -fix-only-warnings">, applies fixits for warnings only, not errors Combining "-fixit-recompile -fixit-to-temporary" allows testing the result of fixits without touching the original sources. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149027 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/FrontendTool/ExecuteCompilerInvocation.cpp')
-rw-r--r--lib/FrontendTool/ExecuteCompilerInvocation.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/FrontendTool/ExecuteCompilerInvocation.cpp b/lib/FrontendTool/ExecuteCompilerInvocation.cpp
index 2782a85beb..9f2bdf25be 100644
--- a/lib/FrontendTool/ExecuteCompilerInvocation.cpp
+++ b/lib/FrontendTool/ExecuteCompilerInvocation.cpp
@@ -87,6 +87,10 @@ static FrontendAction *CreateFrontendAction(CompilerInstance &CI) {
if (!Act)
return 0;
+ if (CI.getFrontendOpts().FixAndRecompile) {
+ Act = new FixItRecompile(Act);
+ }
+
// Potentially wrap the base FE action in an ARC Migrate Tool action.
switch (CI.getFrontendOpts().ARCMTAction) {
case FrontendOptions::ARCMT_None: