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

Inline transparent implicit parameters when typing Unapply trees #19646

Merged
merged 1 commit into from
Feb 27, 2024

Conversation

nicolasstucki
Copy link
Contributor

@nicolasstucki nicolasstucki commented Feb 8, 2024

We needed to delay the inlining of the transparent inline when typing the unapply function application. We used the NoInline mode, but this also stopped the inlining of the arguments of the unapply. To fix this we target more precisely the inlining of the unapply method and not the implicit arguments. To do this we detect the dummy argument that is used type the unapply as an application, before it is transformed into a pattern.

Fixes #19623
Fixes solution added in #19380

@nicolasstucki nicolasstucki self-assigned this Feb 8, 2024
@nicolasstucki nicolasstucki marked this pull request as ready for review February 9, 2024 07:59
@nicolasstucki nicolasstucki requested a review from odersky February 9, 2024 08:05
@odersky odersky assigned nicolasstucki and unassigned odersky Feb 15, 2024
We needed to delay the inlining of the transparent inline when typing
the unapply function application. We used the NoInline mode, but this
also stopped the inlining of the arguments of the unapply. To fix this
we target more precisely the inlining of the unapply method and not the
implicit arguments. To do this we detect the dummy argument that is used
type the unapply as an application, before it is transformed into a pattern.

Fixes scala#19623
Copy link
Contributor

@odersky odersky left a comment

Choose a reason for hiding this comment

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

LGTM. Glad we did not need to use that mode bit.

@odersky odersky merged commit 4810559 into scala:main Feb 27, 2024
19 checks passed
@odersky odersky deleted the fix-19623 branch February 27, 2024 20:38
@Kordyjan Kordyjan added this to the 3.4.2 milestone Mar 28, 2024
WojciechMazur added a commit that referenced this pull request Jul 5, 2024
…trees" to LTS (#21048)

Backports #19646 to the LTS branch.

PR submitted by the release tooling.
[skip ci]
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.

Regression in tarao/record4s - transparent inline looses type dependent type info in match
3 participants