Skip to content

Drop Module flag from lifted symbols. #700

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Jul 1, 2015

Conversation

odersky
Copy link
Contributor

@odersky odersky commented Jun 26, 2015

Reason: A lifted module is no longer a module (i.e. singleton object) in the scope
to which it is lifted.

Fixes #689. Review by @DarkDimius

odersky added 7 commits June 26, 2015 18:12
Thistypes erased to the underlying class. This is wrong. When seen as part of some other type,
a ThisType has to erase to the erasure of the underlying type (i.e. the erasure if the selftype
of the class). unittest-collections.scala failed with a MethodNotFound error because the erasure
was computed incorrectly.

On the other hand, a tree with a ThisType type, should keep the type, analogous to a
tree with a TermRef type.
The file consisted of just a deprecation warning. Not sure what was deprecated; neither dotty
nor scalac find anything wrong with it.
There's one behavioral change: on typedSelectFromTypeTree, we use erasedType as for a notmal ref.
Before semiEraseVCs was always set to false here. I don't see how the treatment should be different.
E.g. it should not matter if we see a

     x.y
or

     T#y
Checking that constraints are closed caused cyclic reference exceptions in
DottyBackedInterface. What's worrying is that these were seemingly not checked
by the checkin tests. Or maybe there is some dependcy on compilation order that triggers
the erros only in my setup.
Replace by the pair of methods erasure/valueErasure.
The boolean parameter is still kept, but only as a
confuration parameter of the erasure objects.
Uncommented parts that were left accidentally commented out when debugging.
Reason: A lifted module is no longer a module (i.e. singleton object) in the scope
to which it is lifted.

Fixes scala#689.
@odersky odersky force-pushed the fix/#689-lifted-modules branch from e5c9a7c to b50f9ab Compare June 26, 2015 16:18
@odersky
Copy link
Contributor Author

odersky commented Jun 26, 2015

Rebased on top of pending #697

DarkDimius added a commit that referenced this pull request Jul 1, 2015
@DarkDimius DarkDimius merged commit 11b7963 into scala:master Jul 1, 2015
@allanrenucci allanrenucci deleted the fix/#689-lifted-modules branch December 14, 2017 19:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants