Re: incompatible signatur syntax within instance definition

2003-12-07 Thread Fergus Henderson
On 05-Dec-2003, Christian Maeder <[EMAIL PROTECTED]> wrote: > >instance Show a => Show (List a) where > >showsPrec _ Nil = showString "[]" > >showsPrec _ l = > >showString "[" . showsl l . showString "]" > >where -- showsl :: List a -> ShowS-- for ghc > > -

Re: incompatible signatur syntax within instance definition

2003-12-05 Thread Christian Maeder
I've just noticed that I used ghc with -fglasgow-exts. Without extensions hugs, ghc und nhc98 consistently need the constraint in the type signature (below) showsl :: Show a => List a -> ShowS Switching the extensions on, breaks this code, however (ghc only). Christian I wrote: Hi, if I tr

incompatible signatur syntax within instance definition

2003-12-05 Thread Christian Maeder
Hi, if I try to supply a signatur for the local function "showsl" below, then ghc rejects a constraint (Show a) whereas hugs (and nhc98) needs this constraint. What should be the correct notation? (apart from omitting any signature) Cheers Christian (BTW, I would appreciate if the (instantiat