RE: package name mismatch

Simon Marlow wrote:
It must have been only a warning in 5.02.3, or I could never have compiled it there. (Before 5.02.3 we didn't use the package system like this at all.)
[snip]
Can't you just fix your build so that the situation doesn't occur?
[snip] In fact I have been unable to reproduce the problem with ghc5.04 anyway. My guess would be that GHC now searches the package directories before the current directory. So we're all happy, unless someone wants to override a module in an imported package. Even then a better solution would be to write another package containing the altered module, and put it first in the search path.
Is the order in which GHC looks for imported modules specified anywhere?
No, but our position is that you shouldn't have more than one module with the same name, regardless of whether they are in separate packages or not, and that the import path for the home package should not overlap with the import path for any other package. The only exception is perhaps two packages that aren't intended to be used together. Cheers, Simon
participants (1)
-
Simon Marlow