Add flipped fmap
ekmett at gmail.com
Thu Apr 8 16:15:55 EDT 2010
I'd strongly discourage removing <$> from Control.Applicative, as it has
been there since the start and basically every single client of
Control.Applicative would break and have to add a second import.
The idiom of foo <$> bar <*> baz <*> ... is the whole point of using an
Applicative after all!
I laud the goal of everything having exactly one place to be, but here I
think practical considerations override.
On Thu, Apr 8, 2010 at 4:07 PM, Bas van Dijk <v.dijk.bas at gmail.com> wrote:
> On Thu, Apr 8, 2010 at 9:38 PM, Isaac Dupree
> > This parallelism also suggests to me that <$$> should be placed (only) in
> > Control.Applicative, which is where <*>, <$>, and <**> reside. Yeah, I
> > that's annoying...
> That's indeed annoying.
> What about removing <$> and <$ from Control.Applicative?
> One advantage is that this reduces the complexity tax of
> One disadvantage is that this will surely break some code. Especially
> because, for some weird reason, Data.Functor is not know to hoogle.
> And <$> is reported to be only exported by Control.Applicative
> Let's save this for a new proposal however...
> Jonathan, thanks for the equational law relating <$$> and <**>:
> a <$$> f = a <**> return f
> this has strongly put me back in the +1 camp :-)
> Libraries mailing list
> Libraries at haskell.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Libraries