Should foldl' be added to the post-"Plan FTP" Prelude

Kazu Yamamoto (=?iso-2022-jp?B?GyRCOzNLXE9CSScbKEI=?=) kazu at
Thu Feb 26 00:31:45 UTC 2015

> I would love to have foldl' as part of the Prelude. I use it quite
> frequently and it seems like a beginner trap to have foldl but not foldl'
> (which is almost always the better choice). I see that foldMap has been
> added (in addition to all of Monoid and Traversable), why was foldl' left
> out?

That is one way but I think another way is to make foldl strict:

I'm tired of explaining the difference of foldl and foldl' to
beginners. :-)


More information about the Libraries mailing list