[commit: ghc] master: Don't make -C imply -fvia-C (acb0cd9)

Ian Lynagh igloo at earth.li
Fri Jan 11 21:51:51 CET 2013


Repository : ssh://darcs.haskell.org//srv/darcs/ghc

On branch  : master

http://hackage.haskell.org/trac/ghc/changeset/acb0cd9485b3f9eb96480ff25b00b66038e1b090

>---------------------------------------------------------------

commit acb0cd9485b3f9eb96480ff25b00b66038e1b090
Author: Ian Lynagh <ian at well-typed.com>
Date:   Fri Jan 11 18:44:01 2013 +0000

    Don't make -C imply -fvia-C
    
    All -fvia-C does nowadays is print a warning saying that it doesn't
    do anything.

>---------------------------------------------------------------

 ghc/Main.hs |   10 +---------
 1 files changed, 1 insertions(+), 9 deletions(-)

diff --git a/ghc/Main.hs b/ghc/Main.hs
index 05a986d..cca4581 100644
--- a/ghc/Main.hs
+++ b/ghc/Main.hs
@@ -545,7 +545,7 @@ mode_flags =
                                             addFlag "-no-link" f))
   , Flag "M"            (PassFlag (setMode doMkDependHSMode))
   , Flag "E"            (PassFlag (setMode (stopBeforeMode anyHsc)))
-  , Flag "C"            (PassFlag setGenerateC)
+  , Flag "C"            (PassFlag (setMode (stopBeforeMode HCc)))
   , Flag "S"            (PassFlag (setMode (stopBeforeMode As)))
   , Flag "-make"        (PassFlag (setMode doMakeMode))
   , Flag "-interactive" (PassFlag (setMode doInteractiveMode))
@@ -553,14 +553,6 @@ mode_flags =
   , Flag "e"            (SepArg   (\s -> setMode (doEvalMode s) "-e"))
   ]
 
-setGenerateC :: String -> EwM ModeM ()
-setGenerateC f = do -- TODO: We used to warn and ignore when
-                    -- unregisterised, but we no longer know whether
-                    -- we are unregisterised at this point. Should
-                    -- we check later on?
-                    setMode (stopBeforeMode HCc) f
-                    addFlag "-fvia-C" f
-
 setMode :: Mode -> String -> EwM ModeM ()
 setMode newMode newFlag = liftEwM $ do
     (mModeFlag, errs, flags') <- getCmdLineState





More information about the ghc-commits mailing list