From 4c177fb1b821a2ac8d463bb8e7862d55eb7c1d25 Mon Sep 17 00:00:00 2001 From: sof Date: Thu, 30 Apr 1998 19:49:03 +0000 Subject: [PATCH 1/1] [project @ 1998-04-30 19:49:01 by sof] Use , as element separator in lists and tuples not comma followed by space (important stuffcvs-diff PrelBase.lhs) --- ghc/lib/std/PrelBase.lhs | 2 +- ghc/lib/std/PrelTup.lhs | 20 ++++++++++---------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/ghc/lib/std/PrelBase.lhs b/ghc/lib/std/PrelBase.lhs index d283d59..092d4df 100644 --- a/ghc/lib/std/PrelBase.lhs +++ b/ghc/lib/std/PrelBase.lhs @@ -759,7 +759,7 @@ showList__ showx [] = showString "[]" showList__ showx (x:xs) = showChar '[' . showx x . showl xs where showl [] = showChar ']' - showl (x:xs) = showString ", " . showx x . showl xs + showl (x:xs) = showChar ',' . showx x . showl xs showSpace :: ShowS showSpace = {-showChar ' '-} \ xs -> ' ' : xs diff --git a/ghc/lib/std/PrelTup.lhs b/ghc/lib/std/PrelTup.lhs index daccfb8..64307ff 100644 --- a/ghc/lib/std/PrelTup.lhs +++ b/ghc/lib/std/PrelTup.lhs @@ -86,29 +86,29 @@ data (,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,) a b c d e f g h i j k l m n o p q r \begin{code} instance (Show a, Show b) => Show (a,b) where - showsPrec p (x,y) = showChar '(' . shows x . showString ", " . + showsPrec p (x,y) = showChar '(' . shows x . showChar ',' . shows y . showChar ')' showList = showList__ (showsPrec 0) instance (Show a, Show b, Show c) => Show (a, b, c) where - showsPrec p (x,y,z) = showChar '(' . showsPrec 0 x . showString ", " . - showsPrec 0 y . showString ", " . + showsPrec p (x,y,z) = showChar '(' . showsPrec 0 x . showChar ',' . + showsPrec 0 y . showChar ',' . showsPrec 0 z . showChar ')' showList = showList__ (showsPrec 0) instance (Show a, Show b, Show c, Show d) => Show (a, b, c, d) where - showsPrec p (w,x,y,z) = showChar '(' . showsPrec 0 w . showString ", " . - showsPrec 0 x . showString ", " . - showsPrec 0 y . showString ", " . + showsPrec p (w,x,y,z) = showChar '(' . showsPrec 0 w . showChar ',' . + showsPrec 0 x . showChar ',' . + showsPrec 0 y . showChar ',' . showsPrec 0 z . showChar ')' showList = showList__ (showsPrec 0) instance (Show a, Show b, Show c, Show d, Show e) => Show (a, b, c, d, e) where - showsPrec p (v,w,x,y,z) = showChar '(' . showsPrec 0 v . showString ", " . - showsPrec 0 w . showString ", " . - showsPrec 0 x . showString ", " . - showsPrec 0 y . showString ", " . + showsPrec p (v,w,x,y,z) = showChar '(' . showsPrec 0 v . showChar ',' . + showsPrec 0 w . showChar ',' . + showsPrec 0 x . showChar ',' . + showsPrec 0 y . showChar ',' . showsPrec 0 z . showChar ')' showList = showList__ (showsPrec 0) \end{code} -- 1.7.10.4