Overloadable list type notation

Carter Schonwald carter.schonwald at gmail.com
Tue Feb 17 04:37:07 UTC 2015

i think that thats only expressible with the style of parsing that agda mix
fix does, and for a variety of reasons I'm somewhat skeptical of the same
being viable for ghc for the forseeable future.

On Mon, Feb 16, 2015 at 11:30 PM, Greg Weber <greg at gregweber.info> wrote:

> I had an idea whose goal is to ease people into Foldable, Traversable, etc.
> There could be a notation that shows the generalization that is occurring.
> map :: Functor [_] => (a -> b) -> [a] -> [b]
> This means that the syntax for the list type is now syntax for the
> variable created by the Functor constraint.
> Adding such a thing to the language is probably not a good idea, but
> someone might possibly like such a notation for pedagogy. Of course, it
> will be pointed out that a Functor is not just a container. But Foldable is
> sometimes expressed as "anything that toList can be called on", so it
> should make sense there.
> Greg Weber
> _______________________________________________
> Libraries mailing list
> Libraries at haskell.org
> http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/libraries/attachments/20150216/f00b13b9/attachment.html>

More information about the Libraries mailing list