Fix bug when the combined package DB has duplicate package IDs
authorSimon Marlow <marlowsd@gmail.com>
Thu, 12 Nov 2009 13:51:20 +0000 (13:51 +0000)
committerSimon Marlow <marlowsd@gmail.com>
Thu, 12 Nov 2009 13:51:20 +0000 (13:51 +0000)
commit1c5fb336af84f4d1230984fa4cee6341635d4dfc
tree2815814f0c33ffba13a0892d32ad8572f0ebadb4
parent51b5bc7d63cd9decadba83e1da874a9768f2ccaf
Fix bug when the combined package DB has duplicate package IDs
Someone on IRC reported that they were encountering a strange missing
module error from GHC, and it turned out that they had mtl-1.1.0.2
installed in both the global and local DB, with the same
InstalledPackageId.  The two packages should be interchangeable, but
we were forgetting to eliminate duplicates in part of the
package-processing phase in GHC.

Really I should switch this code over to use the new PackageIndex data
type in Cabal, which ought to make things simpler.
compiler/main/Packages.lhs