[Yhc] Yhc: A first impression

Malcolm Wallace Malcolm.Wallace at cs.york.ac.uk
Sun Jan 7 10:08:08 EST 2007


"Neil Mitchell" <ndmitchell at gmail.com> writes:

> > 1. I compile HelloWorld.hs by "yhc HelloWorld" and it works fine. However, in
> > contrast to the description on http://haskell.org/haskellwiki/Yhc/Tutorial,
> > the result is deposited in Main.hbc and Main.hi, so to run it, I must use
> > "yhi Main". "yhi HelloWorld" produces a complaint (ERROR: couldn't find
> > module named 'HelloWorld').
> 
> GHC has the same behaviour, at least on Windows, producing main.exe
> always.

And this behaviour was equally annoying under ghc!  It was widely
regarded as a bug, and I'm glad to say it is now fixed with ghc-6.6.

> > 5. Getting to some more meaty things, actually compiling some code, I get the
> > message "Error: Context for Prelude.Num needed in left hand pattern at
> > 98:19-98:23."
> 
> Sounds like an nhc bug that carried over. I'll open a bug report for it.

Yep, it is an old bug, noted for ages on the nhc98 webpages.  It has
something to do with the (lack of the) monomorphism restriction.

Regards,
    Malcolm


More information about the Yhc mailing list