[project @ 2001-10-22 13:45:15 by simonmar]
authorsimonmar <unknown>
Mon, 22 Oct 2001 13:45:15 +0000 (13:45 +0000)
committersimonmar <unknown>
Mon, 22 Oct 2001 13:45:15 +0000 (13:45 +0000)
Default verbosity mode is always 1, and we don't print the
"Compiling ( foo.hs, foo.o )" message if we're in OneShot mode.

Fixes recently introduced problem where the "compilation IS NOT
required" message isn't printed at all in OneShot mode.

ghc/compiler/main/HscMain.lhs
ghc/compiler/main/Main.hs

index 0a95cec..773e6f5 100644 (file)
@@ -207,7 +207,7 @@ hscRecomp ghci_mode dflags have_object
        ; let toInterp = dopt_HscLang dflags == HscInterpreted
        ; let toNothing = dopt_HscLang dflags == HscNothing
 
-       ; when (verbosity dflags >= 1) $
+       ; when (ghci_mode /= OneShot && verbosity dflags >= 1) $
                hPutStrLn stderr ("Compiling " ++ 
                        compMsg (not toInterp) mod location);
 
index b11326c..78bec0c 100644 (file)
@@ -1,7 +1,7 @@
 {-# OPTIONS -fno-warn-incomplete-patterns -optc-DNON_POSIX_SOURCE #-}
 
 -----------------------------------------------------------------------------
--- $Id: Main.hs,v 1.87 2001/08/14 13:40:08 sewardj Exp $
+-- $Id: Main.hs,v 1.88 2001/10/22 13:45:15 simonmar Exp $
 --
 -- GHC Driver program
 --
@@ -211,10 +211,7 @@ main =
                                 -- leave out hscOutName for now
                                 hscOutName = panic "Main.main:hscOutName not set",
 
-                                verbosity = case mode of
-                                               DoInteractive -> 1
-                                               DoMake        -> 1
-                                               _other        -> 0,
+                                verbosity = 1
                                })
 
        -- the rest of the arguments are "dynamic"