[GHC] #7781: Dumb error message when trying to runghc a module with no 'main' function

GHC cvs-ghc at haskell.org
Thu Mar 21 05:24:28 CET 2013


#7781: Dumb error message when trying to runghc a module with no 'main' function
-----------------------------+----------------------------------------------
Reporter:  guest             |          Owner:                  
    Type:  bug               |         Status:  new             
Priority:  normal            |      Component:  Compiler        
 Version:  7.6.2             |       Keywords:                  
      Os:  Unknown/Multiple  |   Architecture:  Unknown/Multiple
 Failure:  None/Unknown      |      Blockedby:                  
Blocking:                    |        Related:                  
-----------------------------+----------------------------------------------
 $ runghc Log.hs

 Log.hs:1:33:
     Not in scope: `main'
     Perhaps you meant `min' (imported from Prelude)


 It really should say something like:

     No `main` function found. Can't run a module with no `main'.

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/7781>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler



More information about the ghc-tickets mailing list