SI-8244 Fix raw type regression under separate compilation #3519
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.
[Rebase of #3483 that also avoids overlapping test files t8244b/ became t8244e/]
In #1901, handling of raw types encountered in signatures during class
file parsing was changed to work in the same manner as
classExistentialType
, by usingexistentialAbstraction(cls.tparms, cls.tpe_*)
But this never creates fresh existential symbols, and just sticks
the class type parameters it
quantified
:In the enclosed test case, this class type parameter was substituted
during
typeOf[X] memberType sym
, which led us unsoundly thinkingthat
Raw[_]
wasRaw[X]
.I've added a TODO comment to review the other usages of
classExistentialType
.Test variations include joint and separate compilation, and the
corresponding Scala-only code. All fail with type errors now,
as we expect. I've also added a distillation of a bootstrap
error that failed when I forgot to wrap the
existentialType
.