fclabels 2.0.1.1 → 2.0.2
raw patch · 4 files changed
+17/−4 lines, 4 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
+ Data.Label: for :: Arrow arr => Lens arr (j -> a) (i -> b) -> Lens arr (f -> g) (o -> i) -> Point arr g j f o
+ Data.Label.Poly: for :: Arrow arr => Lens arr (j -> a) (i -> b) -> Lens arr (f -> g) (o -> i) -> Point arr g j f o
Files
- CHANGELOG +3/−0
- fclabels.cabal +3/−3
- src/Data/Label.hs +2/−1
- src/Data/Label/Poly.hs +9/−0
CHANGELOG view
@@ -1,5 +1,8 @@ CHANGELOG +2.0.2+ - Add `for` as a synonym for `>-` to avoid a clash with the Arrows extension.+ 2.0.1.1 - Allow mtl 2.2.* and transformers 0.4.*
fclabels.cabal view
@@ -1,5 +1,5 @@ Name: fclabels-Version: 2.0.1.1+Version: 2.0.2 Author: Sebastiaan Visser, Erik Hesselink, Chris Eidhof, Sjoerd Visscher with lots of help and feedback from others. Synopsis: First class accessor labels implemented as lenses.@@ -47,9 +47,9 @@ See "Data.Label.Base" and "Data.Label.Monadic" for more information. .- * /Changelog from 2.0.0.5 to 2.0.1/+ * /Changelog from 2.0.1.1 to 2.0.2/ .- > - Widened TH dependencies.+ > - Add `for` as a synonym for `>-` to avoid a clash with the Arrows extension. Maintainer: Sebastiaan Visser <code@fvisser.nl> Homepage: https://github.com/sebastiaanvisser/fclabels
src/Data/Label.hs view
@@ -127,6 +127,7 @@ , point , (>-)+, for -- * Working with isomorphisms. --@@ -169,7 +170,7 @@ where import Data.Label.Point (Iso(..), inv)-import Data.Label.Poly (point, (>-))+import Data.Label.Poly (point, (>-), for) import Data.Label.Mono (iso, (:->)) import Data.Label.Derive (mkLabel, mkLabels, getLabel, fclabels)
src/Data/Label/Poly.hs view
@@ -18,6 +18,7 @@ , set , iso , (>-)+, for ) where @@ -101,6 +102,14 @@ (>-) (Lens (Point f _)) (Lens l) = Point (Point.get l) (Point.modify l . first (arr (f .))) (>-) (Lens (Point f _)) Id = Point id (app . first (arr (f .))) (>-) Id l = unpack l++-- | Non-operator version of `>-`, since it clashes with an operator+-- when the Arrows language extension is used.++infix 7 `for`++for :: Arrow arr => Lens arr (j -> a) (i -> b) -> Lens arr (f -> g) (o -> i) -> Point arr g j f o+for = (>-) -------------------------------------------------------------------------------