Skip to content

Commit 526970f

Browse files
Fixing cases to Ord interface implementation for RRBVector (Unsized).
1 parent e8cafb2 commit 526970f

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/Data/RRBVector/Unsized/Internal.idr

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -221,15 +221,15 @@ Ord a => Ord (Tree a) where
221221
compare (Balanced arr1) (Unbalanced arr2 _) =
222222
compare arr1 arr2
223223
compare (Balanced arr1) (Leaf arr2) =
224-
compare (toList arr1) (toList arr2)
224+
compare (concat $ map toList arr1) (toList arr2)
225225
compare (Unbalanced arr1 _) (Balanced arr2) =
226226
compare arr1 arr2
227227
compare (Unbalanced arr1 _) (Leaf arr2) =
228-
compare (toList arr1) (toList arr2)
228+
compare (concat $ map toList arr1) (toList arr2)
229229
compare (Leaf arr1) (Balanced arr2) =
230-
compare (toList arr1) (toList arr2)
230+
compare (toList arr1) (concat $ map toList arr2)
231231
compare (Leaf arr1) (Unbalanced arr2 _) =
232-
compare (toList arr1) (toList arr2)
232+
compare (toList arr1) (concat $ map toList arr2)
233233

234234
--------------------------------------------------------------------------------
235235
-- Show Utilities (Tree)

0 commit comments

Comments
 (0)