1919 * @see Fn1
2020 */
2121@ FunctionalInterface
22- public interface Profunctor <A , B > {
22+ public interface Profunctor <A , B , PF extends Profunctor > {
2323
2424 /**
2525 * Contravariantly map over the left parameter.
@@ -28,7 +28,7 @@ public interface Profunctor<A, B> {
2828 * @param fn the mapping function
2929 * @return a profunctor over Z (the new left parameter type) and C (the same right parameter type)
3030 */
31- default <Z > Profunctor <Z , B > diMapL (Function <Z , A > fn ) {
31+ default <Z > Profunctor <Z , B , PF > diMapL (Function <Z , A > fn ) {
3232 return diMap (fn , id ());
3333 }
3434
@@ -40,7 +40,7 @@ default <Z> Profunctor<Z, B> diMapL(Function<Z, A> fn) {
4040 * @param fn the mapping function
4141 * @return a profunctor over A (the same left parameter type) and C (the new right parameter type)
4242 */
43- default <C > Profunctor <A , C > diMapR (Function <B , C > fn ) {
43+ default <C > Profunctor <A , C , PF > diMapR (Function <B , C > fn ) {
4444 return diMap (id (), fn );
4545 }
4646
@@ -54,5 +54,5 @@ default <C> Profunctor<A, C> diMapR(Function<B, C> fn) {
5454 * @param rFn the right parameter mapping function
5555 * @return a profunctor over Z (the new left parameter type) and C (the new right parameter type)
5656 */
57- <Z , C > Profunctor <Z , C > diMap (Function <Z , A > lFn , Function <B , C > rFn );
57+ <Z , C > Profunctor <Z , C , PF > diMap (Function <Z , A > lFn , Function <B , C > rFn );
5858}
0 commit comments