From e2fbc10ebdb5d85813fd15c5dd371ee8e1e87a22 Mon Sep 17 00:00:00 2001 From: Profpatsch Date: Sat, 13 Nov 2021 02:18:27 +0100 Subject: [PATCH] feat(users/Profpatsch/lens): add _ as reverse function application Change-Id: I0bcd997ea469ff55d2170027184fc5bd10b44e00 Reviewed-on: https://cl.tvl.fyi/c/depot/+/3847 Reviewed-by: Profpatsch Tested-by: BuildkiteCI --- users/Profpatsch/lens.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/users/Profpatsch/lens.nix b/users/Profpatsch/lens.nix index db102d8b1..58d9c27f5 100644 --- a/users/Profpatsch/lens.nix +++ b/users/Profpatsch/lens.nix @@ -6,6 +6,8 @@ let comp = f: g: x: f (g x); + _ = v: f: f v; + # Profunctor (p :: Type -> Type -> Type) Profunctor = rec { # dimap :: (a -> b) -> (c -> d) -> p b c -> p a d @@ -113,6 +115,7 @@ let in { inherit id + _ const comp Profunctor