Monad of no `return` Proposal (MRP): Moving `return` out of `Monad`
David Feuer
david.feuer at gmail.com
Fri Sep 25 15:46:49 UTC 2015
It *should* be possible to recognize
return = pure
return x = pure x
pure = return
pure x = return x
and also cases where pure and return are defined the same up to alpha
equivalence. It should also be possible to fix this up automatically, but
there are several different fixes that programmers may want. Many package
maintainers strive to support old GHC versions--some as far back as
7.0--and a few even try to keep their code running in Hugs, although that
seems a bit silly. Those maintainers will probably want to use
MIN_VERSION_base to maintain backwards compatibility. Some of those
packages (e.g., containers) approximate fake versions of that macro for
non-cabal compilation, but such conditional definitions may occur in each
file separately or in a global include file.
On Sep 25, 2015 11:35 AM, "Greg Weber" <greg at gregweber.info> wrote:
> Is the upgrade automatable with tooling that analyzes Haskell source code?
> If so can we provide an executable that will automatically upgrade
> packages?
> Pull requests could even be sent automatically.
>
> On Fri, Sep 25, 2015 at 5:02 AM, Alexander Berntsen <alexander at plaimi.net>
> wrote:
>
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA512
>>
>> Enthusiastic +1 from me too, of course.
>>
>> - --
>> Alexander
>> alexander at plaimi.net
>> https://secure.plaimi.net/~alexander
>> -----BEGIN PGP SIGNATURE-----
>> Version: GnuPG v2
>>
>> iQIcBAEBCgAGBQJWBTfiAAoJENQqWdRUGk8BU00QAMQfZo07CKomsjqcwNCDNqdm
>> ifIhiz2kldR+A/gp6t/8IRf0RG3ZgZfwxhR5s/BWt7yV28napZfTMHPTfV8gE+bm
>> V8AzvsXe/XLa9gTDyxqnY+ovYBDnEqmbX3SU03rRdtcN3jHiNuFkfIEIkRx6+HVx
>> BKfoebxD7r1tgs/4nxjD8HljJEh6W8ux2Q8+sMWiCJEbVN5ixzTzGSk28vT2Ldyl
>> GkoZJoXYM4K3WVCn23UmH9eokbdbnaCu2WRqzGgM7eQf+qqpouSjE3KRL5d9O/pE
>> NMJIrNkC1L613GpfNeHLikOCKd78vbT0xnXyKHwAxv4Cr/7IZI3dyu+5MYwFntrY
>> cdX7PgNQw7RN/tvZ63OOaRQEqvQfiOSdhPdFxAF5MabPNYMZMjIHqJuQseBaiUJf
>> SWOU9oYNWW7XQVaQRVS5bP0KvRUhsA2+QXEd6pnhBEZ6u7qRQhaJowjca/A1TbB/
>> LHVG9nXE04fvc+CRkMK/xZEbuNWiMF0p4CZUiyeuAzhcZ9dge367ExfrTpTSLz8O
>> Gfh04LgWs3rnvc3w8yhJJjcfsHhYZKQJMv40Rn8dgE/hyGFRpwQvBvFolZtFBZiS
>> h6A/MyLDaSJCw3jwj+cU5PGLULGzdfNnTRlJ/jb4/CD2xUEOaQcAd+NvIJOlREcK
>> RZBk4o5MU1aCsujOzjRd
>> =VfnC
>> -----END PGP SIGNATURE-----
>> _______________________________________________
>> Libraries mailing list
>> Libraries at haskell.org
>> http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries
>>
>
>
> _______________________________________________
> 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/20150925/6b2af76e/attachment.html>
More information about the Libraries
mailing list