lens uses Curried (Yoneda f) (Yoneda f) and an internal liftCurriedYoneda to implement confusing. There are other applications where these pieces are more useful separately. For example, you can use a class
class GTraversable t where
gtraverse :: (a -> f b) -> t a -> Curried (Yoneda f) (Yoneda f) a
to implement generic deriving of Traversable that seems to work almost exactly the same as GHC deriving (if you use a modified form of Generic1). Perhaps it would even make sense to add a CurriedYoneda type and explain what it can do for you.
lens
usesCurried (Yoneda f) (Yoneda f)
and an internalliftCurriedYoneda
to implementconfusing
. There are other applications where these pieces are more useful separately. For example, you can use a classto implement generic deriving of
Traversable
that seems to work almost exactly the same as GHC deriving (if you use a modified form ofGeneric1
). Perhaps it would even make sense to add aCurriedYoneda
type and explain what it can do for you.