
I'm going to submit a ticket for this. However, I have a related question:
Do you care about mapM_? Right now it's defined as:
mapM_ f = foldr ((>>) . f) (return ())
whereas it could be:
mapM_ = traverse_
Does this not affect you in the same way (because (>>) allows the same
optimization as Applicative)? Or does this also need to be addressed?
-- Dan
On Mon, May 11, 2015 at 3:15 PM, Simon Marlow
I was hoping that in GHC 7.10 we would make mapM = traverse for lists, but it appears this isn't the case: the Traversable instance for lists overrides mapM to be the manually-defined version in terms of foldr.
Why is this? Fusion?
Unfortunately since I want mapM = traverse (for Haxl) I'll need to continue to redefine it in our custom Prelude.
Cheers, Simon _______________________________________________ Libraries mailing list Libraries@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries