Skip to content

Commit 91ae607

Browse files
authored
Data.Sequence.Internal: canonicalise mappend (#726)
Updates the definition of `Monoid (Seq a)` to use canonical definition of `mappend`, allowing https://gitlab.haskell.org/ghc/ghc/-/merge_requests/3174 to pass
1 parent 7e86f7e commit 91ae607

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

containers/src/Data/Sequence/Internal.hs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -949,7 +949,11 @@ instance Read1 Seq where
949949

950950
instance Monoid (Seq a) where
951951
mempty = empty
952+
#if MIN_VERSION_base(4,9,0)
953+
mappend = (Semigroup.<>)
954+
#else
952955
mappend = (><)
956+
#endif
953957

954958
#if MIN_VERSION_base(4,9,0)
955959
-- | @since 0.5.7

0 commit comments

Comments
 (0)