Ticket #33: Foo.3.hs

File Foo.3.hs, 239 bytes (added by spanne, 14 years ago)
Line 
1newtype Spec = Spec [String]
2
3instance Show Spec where
4   showsPrec _ (Spec defs) = showsDefs defs
5      where showsDefs []     = id
6            showsDefs (d:ds) = (.) (shows d) (showsDefs ds)
7
8main :: IO ()
9main = print (Spec ["A", "B"])