[Haskell-cafe] inference with implicitparams seems broken
Richard Eisenberg
lists at richarde.dev
Thu Mar 24 19:05:56 UTC 2022
> On Mar 24, 2022, at 9:04 AM, rowan goemans <goemansrowan at gmail.com> wrote:
>
> is this by design/expected though?
It is by design, yes. With a sufficiently nuanced expectation, I would also say it's expected. (Though, to be fair, if I were not primed to be thinking about the monomorphism restriction, I can't honestly say I would get it right if quizzed.)
> Would there be interest in fixing this in GHC?
Figuring out when to generalize a local binding is a hard problem. So, there is definitely interest in finding a better way to do it, but I don't think anyone knows a design that meets the most expectations. Language design is hard! :)
Richard
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/haskell-cafe/attachments/20220324/6e1e41d6/attachment.html>
More information about the Haskell-Cafe
mailing list