File tree Expand file tree Collapse file tree 1 file changed +3
-0
lines changed Expand file tree Collapse file tree 1 file changed +3
-0
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,7 @@ import Data.Foldable (class Foldable)
1212import Data.FoldableWithIndex (class FoldableWithIndex )
1313import Data.Functor.Invariant (class Invariant , imapF )
1414import Data.FunctorWithIndex (class FunctorWithIndex )
15+ import Data.Generic.Rep (class Generic )
1516import Data.Maybe (Maybe (..), maybe , maybe' )
1617import Data.Ord (class Ord1 )
1718import Data.Traversable (class Traversable )
@@ -40,6 +41,8 @@ derive instance functorEither :: Functor (Either a)
4041instance functorWithIndexEither :: FunctorWithIndex Unit (Either a ) where
4142 mapWithIndex f = map $ f unit
4243
44+ derive instance genericEither :: Generic (Either a b ) _
45+
4346instance invariantEither :: Invariant (Either a ) where
4447 imap = imapF
4548
You can’t perform that action at this time.
0 commit comments