aboutsummaryrefslogtreecommitdiff
path: root/lib/Driver/Driver.cpp
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2010-12-08 21:33:40 +0000
committerDaniel Dunbar <daniel@zuster.org>2010-12-08 21:33:40 +0000
commit9eb93b07ea913e7ad0bcd15bd3e3662e2760c323 (patch)
tree109d053fdea28fb2040f0da143c3873907ea9db4 /lib/Driver/Driver.cpp
parenta8b988f6ec8e2355c7081b31578843be33027033 (diff)
Driver: M and MM should be grouped together, <rdar://problem/8744831>.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@121284 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Driver/Driver.cpp')
-rw-r--r--lib/Driver/Driver.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/Driver/Driver.cpp b/lib/Driver/Driver.cpp
index 98c1a21559..a3b7167c8b 100644
--- a/lib/Driver/Driver.cpp
+++ b/lib/Driver/Driver.cpp
@@ -800,8 +800,7 @@ void Driver::BuildActions(const ToolChain &TC, const ArgList &Args,
// -{E,M,MM} only run the preprocessor.
if ((FinalPhaseArg = Args.getLastArg(options::OPT_E)) ||
- (FinalPhaseArg = Args.getLastArg(options::OPT_M)) ||
- (FinalPhaseArg = Args.getLastArg(options::OPT_MM))) {
+ (FinalPhaseArg = Args.getLastArg(options::OPT_M, options::OPT_MM))) {
FinalPhase = phases::Preprocess;
// -{fsyntax-only,-analyze,emit-ast,S} only run up to the compiler.
@@ -909,7 +908,7 @@ Action *Driver::ConstructPhaseAction(const ArgList &Args, phases::ID Phase,
case phases::Preprocess: {
types::ID OutputTy;
// -{M, MM} alter the output type.
- if (Args.hasArg(options::OPT_M) || Args.hasArg(options::OPT_MM)) {
+ if (Args.hasArg(options::OPT_M, options::OPT_MM)) {
OutputTy = types::TY_Dependencies;
} else {
OutputTy = types::getPreprocessedType(Input->getType());