[Haskell-beginners] what type is 'Val 9' when 'Val Int' a ctor for 'Expr e'?

Antoine Latter aslatter at gmail.com
Wed Oct 22 17:44:07 EDT 2008

On Wed, Oct 22, 2008 at 4:10 PM, Jason Dusek <jason.dusek at gmail.com> wrote:
>  Can you explain why you think you need that annotation? I
>  can't see an ambiguous interpretation of your code.

The confusion is that the 'Val' constructor is for the 'Expr' type,
which has a phantom type parameter in its type constructor.

Can you load that up into GHCi and type:

> :t val_9

which should cause GHCi to print out what it thinks the type of that
expression is.


More information about the Beginners mailing list