Skip to content
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

Fix quotes with references to path dependent types #17081

Conversation

nicolasstucki
Copy link
Contributor

No description provided.

@nicolasstucki nicolasstucki force-pushed the fix-path-dependent-types-detection-in-quotes branch from 9d0008d to 511b02f Compare March 10, 2023 16:40
@nicolasstucki nicolasstucki self-assigned this Mar 10, 2023
@nicolasstucki nicolasstucki force-pushed the fix-path-dependent-types-detection-in-quotes branch 6 times, most recently from 65ac9f3 to d96d4f3 Compare March 15, 2023 13:30
@nicolasstucki nicolasstucki force-pushed the fix-path-dependent-types-detection-in-quotes branch 3 times, most recently from a0e2a25 to 31d94d7 Compare March 23, 2023 15:16
@nicolasstucki nicolasstucki removed their assignment Mar 24, 2023
@nicolasstucki nicolasstucki marked this pull request as ready for review March 24, 2023 08:46
Comment on lines 660 to 661
for arg <- args if arg.isType do
assert(arg.tpe.isInstanceOf[TypeRef] || arg.tpe.isInstanceOf[TermRef], "Expected TypeRef or TermRef in Hole type args but got: " + arg.tpe)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand this change, can you explain why we do this?

Copy link
Contributor Author

@nicolasstucki nicolasstucki Apr 3, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Before, we assumed that we could only have type references, a reference to a type on some arbitrary path that is represented with a TypeRef (T, x.T, y.x.T). But we missed singleton types represented with a TermRef (a.type, a.b.type, ...).

This was part of another fix that I split out of this PR (see #17138). I removed this change.

@nicolasstucki nicolasstucki force-pushed the fix-path-dependent-types-detection-in-quotes branch from 31d94d7 to f035f10 Compare April 3, 2023 07:49
@nicolasstucki nicolasstucki merged commit f3f96c4 into scala:main Apr 3, 2023
@nicolasstucki nicolasstucki deleted the fix-path-dependent-types-detection-in-quotes branch April 3, 2023 15:08
@Kordyjan Kordyjan added this to the 3.3.1 milestone Aug 1, 2023
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