From 0769cc7c46f4aeb3dd1416a62c0d68648ae5f782 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Mon, 20 Feb 2017 20:53:15 +0100 Subject: Minor cleanup --- lib/Postdelay/PrioMap.hs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'lib/Postdelay/PrioMap.hs') diff --git a/lib/Postdelay/PrioMap.hs b/lib/Postdelay/PrioMap.hs index 2b75984..97705ba 100644 --- a/lib/Postdelay/PrioMap.hs +++ b/lib/Postdelay/PrioMap.hs @@ -2,7 +2,7 @@ module Postdelay.PrioMap ( PrioMap, prioMap, prioMap', _Endo - , prio, prios + , prio, prio', prios , squash , PrioEndo, prioEndo, prioEndo' @@ -68,3 +68,6 @@ prioEndo = prioMap prioEndo' :: Enum p => p -> Iso' (PrioEndo p a) (Endo a) prioEndo' = prioMap' + +prio' :: Enum p => p -> Setter' (PrioEndo p a) a +prio' p = sets $ \(Endo -> mod) -> mappend $ review (prioMap' p) mod -- cgit v1.2.3