[project @ 2005-05-17 07:49:47 by simonmar]
authorsimonmar <unknown>
Tue, 17 May 2005 07:49:47 +0000 (07:49 +0000)
committersimonmar <unknown>
Tue, 17 May 2005 07:49:47 +0000 (07:49 +0000)
Bugfix to previous commit: filenames without an extension are assumed
to be a haskell source filenames with the extension removed (eg. ghc
--make hello should compile hello.hs).

ghc/compiler/main/Main.hs

index 422cfc9..0e9711f 100644 (file)
@@ -372,7 +372,8 @@ doMake sess []    = throwDyn (UsageError "no input files")
 doMake sess srcs  = do 
     let (hs_srcs, non_hs_srcs) = partition haskellish srcs
 
-       haskellish (f,Nothing) = looksLikeModuleName f || isHaskellSrcFilename f
+       haskellish (f,Nothing) = 
+         looksLikeModuleName f || isHaskellSrcFilename f || '.' `notElem` f
        haskellish (f,Just phase) = 
          phase `notElem` [As, Cc, CmmCpp, Cmm, StopLn]