[GHC] #14200: Deprecate WrappedMonad
GHC
ghc-devs at haskell.org
Fri Sep 8 13:17:23 UTC 2017
#14200: Deprecate WrappedMonad
-------------------------------------+-------------------------------------
Reporter: siddhanathan | Owner: (none)
Type: task | Status: new
Priority: normal | Milestone:
Component: libraries/base | Version: 8.2.1
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: None/Unknown | Test Case:
Blocked By: | Blocking:
Related Tickets: #13876 | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Changes (by RyanGlScott):
* cc: hvr, ekmett, core-libraries-committee@… (added)
* related: => #13876
Comment:
I'm inclined to agree here. At one point in time, where `return` was a
canonical class method of `Monad`, it was commonplace to define
`Applicative` and `Functor` methods entirely in terms of `Monad` methods.
But now `return = pure`, and there are
[https://ghc.haskell.org/trac/ghc/wiki/Proposal/MonadOfNoReturn plans] to
eventually remove `return` as a class method of `Monad` entirely. When
this happens, `WrappedMonad` won't be nearly as useful as it once was,
since one won't be able to define `Applicative(pure)` from an arbitrary
`Monad` instance anymore (see also #13876). This makes the utility of a
`WrappedMonad` newtype dubious.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/14200#comment:1>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list