• Ian Lynagh's avatar
    Only look up whether a module's SOURCE-imported if it's in the current package · 0e3d5132
    Ian Lynagh authored
    Suppose we import anotherPackage:M, which exports things from
    anotherPackage:Internal. Then GHC will want to read
    anotherPackage:Internal.hi.
    
    However, if we have also SOURCE-imported thisPackage:Internal then
    we don't want GHC to try to read anotherPackage:Internal.hi-boot
    instead.
    
    The mapping that tells us whether a module is SOURCE-imported uses just
    the module name for the key, so we have to check the package ID before
    looking it up.
    
    Fixes #3007.
    0e3d5132
LoadIface.lhs 28 KB