Skip to content

Backport "Make Ref.apply() return trees usable in the largest scope possible" to 3.3 LTS #287

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

Closed
wants to merge 1 commit into from

Conversation

tgodzik
Copy link

@tgodzik tgodzik commented Apr 24, 2025

Backports scala#22240 to the 3.3.7.

PR submitted by the release tooling.
[skip ci]

Previously for symbols contained in objects (prefixed by, let's say,
'pre'), we would return:
* an Ident if pre contained only static
object and packages;
* Select(This(moduleClassSymbol), sym) if a prefix contained a class.

However, this meant that in the second case, the generated tree would
require the macro to be expanded inside of the object, even though it
should be enough to just expand inside of the innermost class.
This was unexpected and confusing, so it was changed to not return
innermost module classes wrapped with This().

[Cherry-picked 238ba45]
@tgodzik tgodzik closed this Apr 24, 2025
@tgodzik tgodzik deleted the backport-lts-3.3-22240 branch April 24, 2025 14:01
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.

2 participants