[Haskell-cafe] "Lower case" infix type operator variables
Adam Bergmark
adam at bergmark.nl
Wed Sep 3 08:28:38 UTC 2014
it was changed in 7.6 even!
On Wed, Sep 3, 2014 at 9:19 AM, Erik Hesselink <hesselink at gmail.com> wrote:
> Hi Joseph,
>
> The type operator type variable used to be possible, but this was
> changed in (I think) 7.8. See the discussion in threads [0] and [1].
> There were some proposals for alternate syntax for operator type
> variables, but I don't think any of them were implemented. Currently,
> the best you can do is infix textual names, something like:
>
> constA :: Arrow arr => b -> (a `arr` b)
>
> Erik
>
> [0]
> http://www.haskell.org/pipermail/glasgow-haskell-users/2012-January/021611.html
> [1]
> http://www.haskell.org/pipermail/glasgow-haskell-users/2012-September/022845.html
>
> On Wed, Sep 3, 2014 at 8:03 AM, Joseph Abrahamson <me at jspha.com> wrote:
> > I spent a few moments confused by the fact the TypeOperators was
> > insufficient to allow the following type to be parsed
> >
> > constA :: Arrow (~>) => b -> (a ~> b)
> >
> > My current intuition is that since I *can* write things like
> >
> > newtype (~>) a b = A (a -> b)
> >
> > there is clashing in the type operator space for “upper case” and “lower
> > case” identifiers. Is it possible or advisable to mitigate this clash and
> > provide some syntax for “type operator variables”?
> > Joseph
> >
> > _______________________________________________
> > Haskell-Cafe mailing list
> > Haskell-Cafe at haskell.org
> > http://www.haskell.org/mailman/listinfo/haskell-cafe
> >
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20140903/4611cafe/attachment.html>
More information about the Haskell-Cafe
mailing list