#2360: More information in occurs check message
--------------------------------+-------------------------------------------
    Reporter:  ajd              |       Owner:          
        Type:  feature request  |      Status:  new     
    Priority:  normal           |   Component:  Compiler
     Version:  6.8.2            |    Severity:  normal  
    Keywords:                   |    Testcase:          
Architecture:  Unknown          |          Os:  Unknown 
--------------------------------+-------------------------------------------
 {{{
 $ cat A.hs
 module A
   where

 foo :: [a] -> a
 foo = id
 $ ghc -c A.hs

 A.hs:5:0:
     Occurs check: cannot construct the infinite type: a = [a]
     When generalising the type(s) for `foo'
 }}}
 It would be nice if GHC could give more information about where and how
 the error is being generated, for example which expressions are making it
 try to unify a and [a]. (Especially in more complicated functions, it can
 be difficult to track down the bug.)

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/2360>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to