From: simonmar Date: Tue, 17 May 2005 07:49:47 +0000 (+0000) Subject: [project @ 2005-05-17 07:49:47 by simonmar] X-Git-Tag: Initial_conversion_from_CVS_complete~539 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=b59217601ccb7dce4206a65599be0cecbdd5545c;p=ghc-hetmet.git [project @ 2005-05-17 07:49:47 by simonmar] 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). --- diff --git a/ghc/compiler/main/Main.hs b/ghc/compiler/main/Main.hs index 422cfc9..0e9711f 100644 --- a/ghc/compiler/main/Main.hs +++ b/ghc/compiler/main/Main.hs @@ -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]