You can find it in the composition library along with other compositions of higher order functions. This statement is not defined in base . If you don't want to add a (very small) package as a dependency, just define it yourself, although I would use a more generalized version that uses fmap :
(.:) :: (Functor f, Functor g) => (a -> b) -> f (ga) -> f (gb) (.:) = fmap fmap fmap
which just fmap performs the function through two layers of functors. For functions, all three of these fmap specialize in (.) .
source share