[Haskell-cafe] types and braces

Conor McBride conor at strictlypositive.org
Wed Apr 15 11:13:08 EDT 2009


On 15 Apr 2009, at 16:01, Lennart Augustsson wrote:

> I'd suggest using some different kind of brackets to relieve the
> misery, like {| |}.

That would speed up my tinkering, certainly.

I did have a d'oh moment: you can write

   data Foo = Moo {goo :: Int}  -- braces where a type goes

and indeed, commenting out field declarations makes happy
happy. However, these { exp } guys never stand as types of
things, only as parameters of types, so it might be possible
to resolve the problem without fat brackets. Whether it's
worth it is another matter...

Cheers

Conor



More information about the Haskell-Cafe mailing list