Skip to content

Commit

Permalink
precise-side-effects: Improve :- and :-- documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
queezle42 committed Dec 18, 2023
1 parent ab89a0a commit 491f30f
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion precise-side-effects/src/Control/Exception/Ex.hs
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,8 @@ instance (n :< as, ns :<< as) => (n ': ns) :<< as
-- The rhs may also be of type `Ex`, in which case all possible exceptions are
-- removed from the lhs.
--
-- When the rhs is `SomeException`, the resulting type list is empty.
--
-- The lhs must not contain `Ex`.
type (:-) :: [Type] -> Type -> [Type]
type family a :- b where
Expand All @@ -79,11 +81,13 @@ type family a :- b where
(r ': xs) :- r = xs :- r
(x ': xs) :- r = x ': (xs :- r)

-- | Remove an exception from a type-level list.
-- | Remove a list of exceptions from a type-level list.
--
-- The rhs may also contain type `Ex`, in which case all possible exceptions are
-- removed from the lhs.
--
-- When the rhs contains `SomeException`, the resulting type list is empty.
--
-- The lhs must not contain `Ex`.
type (:--) :: [Type] -> [Type] -> [Type]
type family a :-- b where
Expand Down

0 comments on commit 491f30f

Please sign in to comment.