Completed switch to `Foldable` folds

Experiments with `pipes` showed the exact same improvement in fusion after
implementing functions directly in terms of `Data.Foldable.foldr` so this seems
to be a pretty reliable phenomenon.