Records in Haskell

Ian Lynagh igloo at
Thu Sep 15 16:43:51 CEST 2011

On Thu, Sep 15, 2011 at 08:47:30AM +0000, Simon Peyton-Jones wrote:
> Provoked the (very constructive) Yesod blog post on "Limitations of Haskell", and the follow up discussion, I've started a wiki page to collect whatever ideas we have about the name spacing issue for record fields.
> As Simon M said on Reddit, this is something we'd like to fix; but we need a consensus on how to fix it.

Re TypeDirectedNameResolution, I would actually prefer it if it were
less general. i.e. if you were to write
then f would be required to be a record selector.

Then there's no need for the "If there is exactly one f whose type
matches that of x" unpleasantness. Instead, the type of x must be
inferred first (without any knowledge about the type of f), and then we
know immediately which f is being referred to.


More information about the Glasgow-haskell-users mailing list