Skip to content

Commit 3de17be

Browse files
Support containers-0.8 in combineEq.
1 parent 747201b commit 3de17be

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/Data/Set/NonEmpty.hs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
{-# LANGUAGE BangPatterns #-}
2+
{-# LANGUAGE CPP #-}
23
{-# LANGUAGE PatternSynonyms #-}
34
{-# LANGUAGE ScopedTypeVariables #-}
45
{-# LANGUAGE TupleSections #-}
@@ -1054,5 +1055,9 @@ combineEq (x :| xs) = go x xs
10541055
where
10551056
go z [] = z :| []
10561057
go z (y : ys)
1058+
#if MIN_VERSION_containers(0,8,0)
1059+
| z == y = go y ys
1060+
#else
10571061
| z == y = go z ys
1062+
#endif
10581063
| otherwise = z NE.<| go y ys

0 commit comments

Comments
 (0)