The title says it all. foldl1 and foldl' both generalized to Foldable , and foldl1' are not. Is this just recent control? Or is it a design choice?
Type foldl1' -
foldl1' :: (a -> a -> a) -> [a] -> a
I expected it to be of the same type as foldl1 :
foldl1 :: Foldable t => (a -> a -> a) -> ta -> a
I also see that foldl1' exported by Data.List , but not Data.Foldable . Perhaps this is related?
haskell fold typeclass
Kevin
source share