[Haskell-cafe] Re: GHC predictability

Neil Mitchell ndmitchell at gmail.com
Tue May 13 17:45:07 EDT 2008


Hi

>  1. What is "ghc-core"?

You actually answer this question as part of question 2. Think of it
as simple Haskell with some additional bits.

>  2. Does anybody know how to actually read GHC's Core output anyway?
> To me,
> it looks almost exactly like very, very complicated Haskell source with a
> suspicious concentration of case expressions - but I understand that in the
> Core language, many constructs actually mean something quite different.

There is one different from standard Haskell I am aware of. In Core,
case x of _ -> 1 will evaluate x, in Haskell it won't. Other than
that, its just Haskell, but without pattern matching and only cases -
hence the rather high number of cases.

Thanks

Neil


More information about the Haskell-Cafe mailing list