[Haskell-cafe] Why does `mzip /= liftM2 (,)`

Theodore Lief Gannon tanuki at gmail.com
Thu Apr 20 19:56:52 UTC 2017


What about:

bisequence :: (Functor f, Bifunctor g) => f (g a b) -> g (f a) (f b)

On Apr 20, 2017 12:21 PM, "MarLinn" <monkleyon at gmail.com> wrote:

>
> The question is why does
>>
>> ```
>> mzip /= liftM2 (,)
>>
>> ```
>>
>
> I don't have any evidence, but my gut feeling is that indeed mzip ==
> liftM2 (,) == liftA2 (,), but that MonadZip just predates many advances,
> and that it's not used often enough to warrant changing. Especially because
> changing stuff in base comes with huge costs and long debates.
>
> Today I would expect something similar to look somewhat more like this:
>
> ```
> class Applicative f => Unzippative f where
>     unzipF :: f (a,b) => (f a, f b)
> ```
>
> I personally can't remember a single time that function would have come in
> handy, so I'm happy with Applicative. And I'm projecting that experience
> onto others and drawing the conclusion of "Meh.".
>
> But if you find out more after
>
>> investigating for next 30 minutes
>>
>
> I'd be interested to hear. ;)
>
> Cheers,
> MarLinn
> _______________________________________________
> Haskell-Cafe mailing list
> To (un)subscribe, modify options or view archives go to:
> http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe
> Only members subscribed via the mailman list are allowed to post.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/haskell-cafe/attachments/20170420/9f9e9bcc/attachment.html>


More information about the Haskell-Cafe mailing list