Hehe, seems like a -W-mutual-recursive-default-methods option is in order.
On 8 July 2010 15:47, Ivan Lazar Miljenovic <ivan.miljeno...@gmail.com> wrote: > "Pasqualino \"Titto\" Assini" <tittoass...@gmail.com> writes: > >> Thanks for the explanation. >> >> What I meant is not that is a bug that it recurses but rather the fact >> that the compiler will accept this incomplete definition without >> complaining. >> >> This problem has bitten me twice while trying to use automatic >> derivation of a data type in another file. >> >> In my innocence I wrote: >> >> instance Show Test >> >> rather than >> >> deriving instance Show Test >> >> I didn't notice the error as GHC seemed to be happy and then when I >> tried to use it: BANG! >> >> Very confusing. >> >> I suppose that Haskell has spoiled me, if it compiles I assume that it >> will work :-) > > As I said, there would be no error as all the methods have a definition > (whether or not they make sense in this case is a different story); it > will still successfully load a file if any methods don't have > definitions but will provide a warning in those situations. > > -- > Ivan Lazar Miljenovic > ivan.miljeno...@gmail.com > IvanMiljenovic.wordpress.com > _______________________________________________ > Haskell-Cafe mailing list > Haskell-Cafe@haskell.org > http://www.haskell.org/mailman/listinfo/haskell-cafe > _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe