File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -40,7 +40,6 @@ newtype MaybeEmpty :: forall k. (k -> Type) -> k -> Type
40
40
newtype MaybeEmpty f a = MaybeEmpty (Maybe (f a ))
41
41
42
42
derive instance Newtype (MaybeEmpty f a ) _
43
- derive newtype instance Show (f a ) => Show (MaybeEmpty f a )
44
43
derive newtype instance Arbitrary (f a ) => Arbitrary (MaybeEmpty f a )
45
44
derive newtype instance Coarbitrary (f a ) => Coarbitrary (MaybeEmpty f a )
46
45
derive newtype instance Semigroup (f a ) => Semigroup (MaybeEmpty f a )
@@ -51,6 +50,9 @@ derive instance Generic (MaybeEmpty f a) _
51
50
derive instance Eq1 f => Eq1 (MaybeEmpty f )
52
51
derive instance Ord1 f => Ord1 (MaybeEmpty f )
53
52
53
+ instance maybeEmptyShow :: (Show (f a )) => Show (MaybeEmpty f a ) where
54
+ show (MaybeEmpty m) = " (MaybeEmpty " <> show m <> " )"
55
+
54
56
instance (Eq1 f , Eq a ) => Eq (MaybeEmpty f a ) where
55
57
eq (MaybeEmpty Nothing ) (MaybeEmpty Nothing ) = true
56
58
eq (MaybeEmpty x) (MaybeEmpty y) = (eq1 <$> x <*> y) == Just true
You can’t perform that action at this time.
0 commit comments