Spotted this refactoring opportunity that HLint doesn't warn me about:
> f g xs = mconcat . fmap g $ xs
> :t f
f :: Monoid c => (a -> c) -> [a] -> c
> :t foldMap
foldMap :: (Foldable t, Monoid m) => (a -> m) -> t a -> m
I know the type is different because of mconcat, but it is a safe thing to suggest?
Side note: just learnt fold while writing this up, which HLint does warn. So probably the real question is, is it aligned with HLint's goal to boost awareness for something like mconcat vs. fold?