[project @ 2002-11-06 12:49:47 by simonpj]
[ghc-hetmet.git] / ghc / compiler / main / Main.hs
index fd84cf0..298107c 100644 (file)
@@ -1,7 +1,7 @@
 {-# OPTIONS -fno-warn-incomplete-patterns -optc-DNON_POSIX_SOURCE #-}
 
 -----------------------------------------------------------------------------
--- $Id: Main.hs,v 1.112 2002/10/15 13:20:18 simonmar Exp $
+-- $Id: Main.hs,v 1.114 2002/10/25 16:54:59 simonpj Exp $
 --
 -- GHC Driver program
 --
@@ -19,6 +19,7 @@ module Main (main) where
 
 #ifdef GHCI
 import InteractiveUI
+import DriverPhases( objish_file )
 #endif
 
 
@@ -42,8 +43,7 @@ import DriverFlags    ( buildStaticHscOpts,
                          dynamic_flags, processArgs, static_flags)
 
 import DriverMkDepend  ( beginMkDependHS, endMkDependHS )
-import DriverPhases    ( Phase(HsPp, Hsc), haskellish_src_file, objish_file,
-                         isSourceFile )
+import DriverPhases    ( Phase(HsPp, Hsc), haskellish_src_file, isSourceFile )
 
 import DriverUtil      ( add, handle, handleDyn, later, splitFilename,
                          unknownFlagsErr, getFileSuffix )
@@ -326,7 +326,7 @@ beginMake fileish_args  = do
                    when (failed ok_flag) (exitWith (ExitFailure 1))
                    return ()
   where
-    looks_like_an_input m = haskellish_src_file m || looksLikeModuleName m
+    looks_like_an_input m = haskellish_src_file m || '.' `notElem` m
 
 
 beginInteractive :: [String] -> IO ()