File tree Expand file tree Collapse file tree 3 files changed +5
-3
lines changed Expand file tree Collapse file tree 3 files changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -6,7 +6,8 @@ Notable changes to this project are documented in this file. The format is based
6
6
7
7
Breaking changes:
8
8
- Added support for PureScript 0.14 and dropped support for all previous versions (#35 , #43 )
9
- - Drop ` Map ` 's ` Semigroup ` and ` Monoid ` instances and provide unbiased instances via ` SemigroupMap ` newtype (#38 )
9
+ - Dropped ` Map ` 's ` Semigroup ` and ` Monoid ` instances and provide unbiased instances via a ` SemigroupMap ` newtype instead (#38 )
10
+ - Updated the ` Show ` instances for (non empty) sets (#46 )
10
11
11
12
New features:
12
13
- Added ` Apply ` instance for ` Map ` (#16 )
Original file line number Diff line number Diff line change @@ -71,7 +71,7 @@ instance eq1Set :: Eq1 Set where
71
71
eq1 = eq
72
72
73
73
instance showSet :: Show a => Show (Set a ) where
74
- show s = " (fromFoldable " <> show (toList s ) <> " )"
74
+ show s = " (fromFoldable " <> show (toUnfoldable s :: Array a ) <> " )"
75
75
76
76
instance ordSet :: Ord a => Ord (Set a ) where
77
77
compare s1 s2 = compare (toList s1) (toList s2)
Original file line number Diff line number Diff line change @@ -26,6 +26,7 @@ module Data.Set.NonEmpty
26
26
27
27
import Prelude hiding (map )
28
28
29
+ import Data.Array.NonEmpty (NonEmptyArray )
29
30
import Data.Eq (class Eq1 )
30
31
import Data.Foldable (class Foldable )
31
32
import Data.List (List , (:))
@@ -56,7 +57,7 @@ instance foldable1NonEmptySet :: Foldable1 NonEmptySet where
56
57
foldl1 f = foldl1 f <<< (toUnfoldable1 :: forall a . NonEmptySet a -> NonEmptyList a )
57
58
58
59
instance showNonEmptySet :: Show a => Show (NonEmptySet a ) where
59
- show s = " (fromFoldable1 " <> show (toUnfoldable1 s :: NonEmptyList a ) <> " )"
60
+ show s = " (fromFoldable1 " <> show (toUnfoldable1 s :: NonEmptyArray a ) <> " )"
60
61
61
62
-- | Create a set with one element.
62
63
singleton :: forall a . a -> NonEmptySet a
You can’t perform that action at this time.
0 commit comments