[Haskell-cafe] Bug in Hugs, Haskell behavior question

Brandon S. Allbery KF8NH allbery at ece.cmu.edu
Fri Apr 4 23:21:30 EDT 2008


On Apr 4, 2008, at 23:15 , Fritz Ruehr wrote:
> In any case, opinions about the behavior aside, there is a Hugs  
> internal error here, so I hope that much is useful.

I am not greatly surprised by that:  a numeric constant like `2' is  
really a polymorphic value `(fromInteger 2 :: Num a => a)' per the  
Report, and if Hugs does that conversion at the wrong time then it  
might well end up attempting to turn a function call into a pattern  
(normally impossible in Haskell, as any attempt would either shadow  
the function or raise a syntax error).

-- 
brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allbery at kf8nh.com
system administrator [openafs,heimdal,too many hats] allbery at ece.cmu.edu
electrical and computer engineering, carnegie mellon university    KF8NH




More information about the Haskell-Cafe mailing list