Records in Haskell

Matthew Farkas-Dyck strake888 at
Fri Nov 4 18:16:38 CET 2011

I really like Simon PJ's "proposal for records in Haskell". Some
reasons for this are:
- Anonymous record types. For example, an anonymous record type can
easily hold ad-hoc keyword arguments. (Oh, just noticed that said in
the document.)
- To quote the document, "We can express polymorphic update (a
standard awkward case) quite nicely". (If I'm not mistaken (please
tell me if so), OverloadedRecordFields proposal fails here.)
- Nice syntax (in my opinion).

Possible record member set syntax:
let x.k = value in x
- No new syntax
- Least Surprise
- Verbosity (especially such: (\ x -> let x.k = value in x))

On 20/10/2011, Simon Peyton-Jones <simonpj at> wrote:
> | Subject: Re: Records in Haskell
> |
> | I have added my proposal to the wiki.The only downsides to it that I can
> see are:
> Thanks to Barney for articulating a proposal for records in Haskell.  Over
> various plane rides and ICFP chats I've worked out some more details.  It's
> not as simple as I'd hoped.
> I'm underwater with stuff at the moment but I did find the time to capture a
> summary here
> Please do correct errors, suggest solutions, or explore variants.
> Simon
> _______________________________________________
> Glasgow-haskell-users mailing list
> Glasgow-haskell-users at

Matthew Farkas-Dyck

More information about the Glasgow-haskell-users mailing list