From d6a748e01924b249cf61bf9a6d1167f4ab49bf4e Mon Sep 17 00:00:00 2001 From: Mikolaj Konarski Date: Sun, 19 May 2024 10:34:33 +0200 Subject: Fix empty lists displayed as ']' --- src/Data/Array/Mixed.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Data/Array/Mixed.hs') diff --git a/src/Data/Array/Mixed.hs b/src/Data/Array/Mixed.hs index 39d969c..aef8ac6 100644 --- a/src/Data/Array/Mixed.hs +++ b/src/Data/Array/Mixed.hs @@ -120,7 +120,7 @@ foldListX _ ZX = mempty foldListX f (x ::% xs) = f x <> foldListX f xs showListX :: forall sh f. (forall n. f n -> ShowS) -> ListX sh f -> ShowS -showListX f l = go "[" l . showString "]" +showListX f l = showString "[" . go "" l . showString "]" where go :: String -> ListX sh' f -> ShowS go _ ZX = id -- cgit v1.2.3-70-g09d2