Skip to content

Commit

Permalink
Update Types.hs
Browse files Browse the repository at this point in the history
Adding missing equality/conversion between IO service types
  • Loading branch information
Heeren committed Oct 5, 2019
1 parent fecc137 commit d8e0e09
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/Ideas/Service/Types.hs
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ instance Equal f => Equal (TypeRep f) where
equal t1 (Iso p b) = fmap (from p .) (equal t1 b)
equal (a :-> b) (c :-> d) = liftM2 (\f g h -> g . h . f)
(equal c a) (equal b d)
equal (IO a) (IO b) = fmap liftM (equal a b)
equal (Pair a b) (Pair c d) = liftM2 (***) (equal a c) (equal b d)
equal (a :|: b) (c :|: d) = liftM2 biMap (equal a c) (equal b d)
equal (List a) (List b) = fmap map (equal a b)
Expand Down

0 comments on commit d8e0e09

Please sign in to comment.