Skip to content

Commit 936fdf8

Browse files
committed
remote: Data.Serializer, expand signature of mapIso/mapPrism*
1 parent cbbc731 commit 936fdf8

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

hnix-store-remote/src/Data/Serializer.hs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,8 @@ mapIsoSerializer
151151
:: Functor (t Get)
152152
=> (a -> b) -- ^ Map over @getS@
153153
-> (b -> a) -- ^ Map over @putS@
154-
-> (Serializer t a -> Serializer t b)
154+
-> Serializer t a
155+
-> Serializer t b
155156
mapIsoSerializer f g s = Serializer
156157
{ getS = f <$> getS s
157158
, putS = putS s . g
@@ -163,7 +164,8 @@ mapPrismSerializer
163164
:: MonadError eGet (t Get)
164165
=> (a -> Either eGet b) -- ^ Map over @getS@
165166
-> (b -> a) -- ^ Map over @putS@
166-
-> (Serializer t a -> Serializer t b)
167+
-> Serializer t a
168+
-> Serializer t b
167169
mapPrismSerializer f g s = Serializer
168170
{ getS = either throwError pure . f =<< getS s
169171
, putS = putS s . g

0 commit comments

Comments
 (0)