Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In #385, we claimed to exploit the fact that GHC only needs package
names in reexport declarations to obviate the need for knowing the
versions (and dependency hashes) of all prebuilt packages. We provided
a test to substantiate this indeed works. But it turns that the test
was not a good test.
The test was flawed because it featured libraries reexporting
base
.It turns out that
base
(along withrts
) are magical in GHC.Because they are so-called "wired-in packages", they are assumed
unique and are therefore not located using a version number. So while
the scheme in #385 worked for
base
, it didn't work in the generalcase, as observed by @lunaris.
The fix consists qualifying all package reexports with full package
id's, not package names. How do we derive a package id given only
a package name? The solution is to have the toolchain generate a dump
of the global package database that ships with the compiler. This is
only needed once for the entire workspace. From this dump, we can
lookup the full package id given any particular name.
Fixes #357.