Preface_specs.StrongStrong is a Profunctor working on product types.
To have a predictable behaviour, the instance of Strong must obey some laws.
Profunctor lawsfst = dimap Pair.swap Pair.swap % sndcontramap_fst Pair.fst = map_snd Pair.fst % fstcontramap_fst (Fun.snd f) % fst = map_snd (Fun.snd f) % fstfst % fst = dimap (fun ((a,b),c) -> (a,(b,c))) (fun (a,(b,c)) -> ((a,b),c)) % fstsnd = dimap Pair.swap Pair.swap % fstcontramap_fst Pair.snd = map_snd Pair.snd % sndcontramap_fst (Fun.fst f) % snd = map_snd (Fun.fst f) % sndsnd % snd = dimap (fun (a,(b,c)) -> ((a,b),c)) (fun ((a,b),c) -> (a,(b,c))) % snd module type WITH_FST = sig ... endMinimal interface using with fst and without Profunctor requirements.
module type WITH_SND = sig ... endMinimal interface using with snd and without Profunctor requirements.
module type WITH_DIMAP_AND_FST = sig ... endMinimal interface using dimap and fst.
module type WITH_CONTRAMAP_FST_AND_MAP_SND_AND_FST = sig ... endMinimal interface using contramap_fst and map_snd and fst.
module type WITH_DIMAP_AND_SND = sig ... endMinimal interface using dimap and snd.
module type WITH_CONTRAMAP_FST_AND_MAP_SND_AND_SND = sig ... endMinimal interface using contramap_fst and map_snd and snd.
module type CORE = sig ... endBasis operations.
module type OPERATION = sig ... endAdditional operations.
module type API = sig ... endThe complete interface of a Strong Profunctor.