[ghc-steering-committee] GHC2021: a final plea for ScopedTypeVariables

Joachim Breitner mail at joachim-breitner.de
Wed Dec 9 13:40:13 UTC 2020


Am Mittwoch, den 09.12.2020, 12:08 +0000 schrieb Simon Peyton Jones via
> I agree with this.  Not having scoped type variables (in any form) is
> a huge blemish.  The existing design may not be perfect, but it’s
> worked rather well for a long time.

The same is true for ViewPatterns, which are even more harmless (clear
syntactic opt-in; no spooky effect at a distance when type signature
and definition are far apart).

There we argued that the fact that we don’t think it’s perfect, and
some wiki page with an alternative design exists, was enough to plea
against it.

Here, the situation seems equivalent (we know of better designs, namely
binding type variables on the LHS of the equation).

Can we justify why we go one way here and another way there? Is it
because ViewPatterns are just mere convenience, and ScopedTypeVariables
are absolutely needed for some things?


Joachim Breitner
  mail at joachim-breitner.de

More information about the ghc-steering-committee mailing list