[ghc-steering-committee] Record dot syntax: vote results

Alejandro Serrano Mena trupill at gmail.com
Wed Apr 1 06:00:54 UTC 2020


El mié., 1 abr. 2020 a las 0:09, Iavor Diatchki (<iavor.diatchki at gmail.com>)
escribió:

> Hello,
>
>    - Indeed, you could write some expressions that might look confusing at
> first, but I don't see why would you?  After all, one could use the exact
> same argument for many other notations in pretty much any programming
> language (e.g., operator precedences can be used to write confusing
> code---it doesn't mean that they are not very useful sometime).
>

But I think it's important to think also of potentially confusing type
errors which may arise if we allow such freedom. I find easier to simply
say "f r .x" cannot be parsed, and then asking the user to disambiguate
between "(f r).x" or "f r.x" than to allow it in the parser and then obtain
a huge error message.

Part of the reason why I'm so concerned about it is that my prediction is
that this is not "just" any other extension. Many people, including
beginners, will enable this by default, since it makes one slightly alien
part of Haskell (field access) look like what they might be used to.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-steering-committee/attachments/20200401/1ea8cba3/attachment.html>


More information about the ghc-steering-committee mailing list