r227591 - Fix regression in r227409 where we were passing -fsyntax-only
Eric Christopher
echristo at gmail.com
Fri Jan 30 10:22:23 PST 2015
Author: echristo
Date: Fri Jan 30 12:22:23 2015
New Revision: 227591
URL: http://llvm.org/viewvc/llvm-project?rev=227591&view=rev
Log:
Fix regression in r227409 where we were passing -fsyntax-only
in all cases.
Patch by Artem Belevich.
Modified:
cfe/trunk/lib/Driver/Tools.cpp
cfe/trunk/test/Driver/gfortran.f90
Modified: cfe/trunk/lib/Driver/Tools.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/Tools.cpp?rev=227591&r1=227590&r2=227591&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/Tools.cpp (original)
+++ cfe/trunk/lib/Driver/Tools.cpp Fri Jan 30 12:22:23 2015
@@ -5166,6 +5166,7 @@ void gcc::Compile::RenderExtraToolArgs(c
break;
case types::TY_PP_Asm:
CmdArgs.push_back("-S");
+ break;
case types::TY_Nothing:
CmdArgs.push_back("-fsyntax-only");
break;
Modified: cfe/trunk/test/Driver/gfortran.f90
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Driver/gfortran.f90?rev=227591&r1=227590&r2=227591&view=diff
==============================================================================
--- cfe/trunk/test/Driver/gfortran.f90 (original)
+++ cfe/trunk/test/Driver/gfortran.f90 Fri Jan 30 12:22:23 2015
@@ -251,3 +251,10 @@
!
! CHECK-PR22234-NOT: clang: error: invalid output type
! CHECK-PR22234: "-fsyntax-only"
+!
+! Regression test for the bug introduced with PR22234 fix.
+! Make sure -fsyntax-only is not passed to gfortran during normal compilation.
+!
+! RUN: %clang -no-canonical-prefixes -target i386-linux -### %s -o %t 2>&1 \
+! RUN: | FileCheck %s --check-prefix=CHECK-PR22234-R
+! CHECK-PR22234-R-NOT: "-fsyntax-only"
More information about the cfe-commits
mailing list