8 Jul
2004
8 Jul
'04
11:20 a.m.
Stephan Herhut <S.A.Herhut@herts.ac.uk> writes:
module B(bar) where instance Foo Integer where
module C(tango) instance Foo Integer where
import B(bar) import C(tango)
But now, ghc complains about two instances of Foo Integer, although there should be none in the namespace main.
I suspect the problem is that instances are always exported and imported, so that GHC sees both in Main, and complains. Perhaps this could be relaxed to allow your situation (where the class isn't used directly in Main anyway)? -kzm -- If I haven't seen further, it is by standing in the footprints of giants