Re: [Haskell] Re: Overloading show

2004-09-10 Thread Stephan Zaubzer
Thank you to all 3 of you! That helped a lot! karczma wrote: Stephan Zaubzer writes: Here my attempts: data Entry a = EmptyEntry | MakeEntry a a showEntry :: (Show a) => Entry a -> String showEntry EmptyEntry = "Empty" showEntry MakeEntry a b = show a ++ ": " ++ show b what am I doing wrong? I hav

[Haskell] Re: Overloading show

2004-09-10 Thread karczma
Stephan Zaubzer writes: Here my attempts: data Entry a = EmptyEntry | MakeEntry a a showEntry :: (Show a) => Entry a -> String showEntry EmptyEntry = "Empty" showEntry MakeEntry a b = show a ++ ": " ++ show b what am I doing wrong? I have seen this way on some tutorials. I believe that if