[Haskell-cafe] Class deriving in GHC 6.8

2007-12-20 Thread Emil Axelsson
Hello all! How come in GHC 6.6 I could to write {-# OPTIONS_GHC -fglasgow-exts -fallow-undecidable-instances #-} data Foo = Foo deriving Show data Bar c = Bar (c Foo) deriving Show but in GHC 6.8.2 I get the error No instance for (Show (c Foo)) arising from the

Re: [Haskell-cafe] Class deriving in GHC 6.8

2007-12-20 Thread Emil Axelsson
After looking more closely at user's manual, I just found that the following works: {-# OPTIONS_GHC -fglasgow-exts -fallow-undecidable-instances #-} data Foo = Foo deriving Show data Bar c = Bar (c Foo) deriving instance Show (c Foo) = Show (Bar c) / Emil On 2007-12-20