GHC support for the new "record" package
Simon Marlow
marlowsd at gmail.com
Fri Jan 23 10:17:35 UTC 2015
On 23/01/2015 04:12, Johan Tibell wrote:
>
>
> On Wed, Jan 21, 2015 at 5:48 PM, Simon Marlow <marlowsd at gmail.com
> <mailto:marlowsd at gmail.com>> wrote:
>
> On 21/01/2015 16:01, Johan Tibell wrote:
>
> My thoughts mostly mirror those of Adam and Edward.
>
> 1) I want something that is backwards compatible.
>
>
> Backwards compatible in what sense? Extension flags provide
> backwards compatibility, because you just don't turn on the
> extension until you want to use it. That's how all the other
> extensions work; most of them change syntax in some way or other
> that breaks existing code.
>
>
> In this case in the sense of avoiding splitting code into a new-Haskell
> vs old-Haskell. This means that existing records should work well (and
> ideally also get the improved name resolution when used in call sites
> that have the pragma enabled) in the new record system.
I understand that position, but it does impose some pretty big
constraints, which may mean the design has to make some compromises.
It's probably not worth discussing this tradeoff until there's actually
a concrete proposal so that we can quantify how much old code would fail
to compile and the cost of any compromises.
Cheers,
Simon
More information about the ghc-devs
mailing list