Skip to content

Add enum type param support in sourceSymbol #18603

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 1 commit into from
Mar 11, 2025

Conversation

rochala
Copy link
Contributor

@rochala rochala commented Sep 27, 2023

Fixes #18541

sourceSymbol should point to the symbol present in source code including enum type params.
The need of such support is that enums are desugared in such a way that enum class type parameters are copied to enum case class. As this is desugar, the copied symbols are not present in source code, thus sourceSymbol should point to enum class type parameter.

@tgodzik
Copy link
Contributor

tgodzik commented Feb 18, 2025

@rochala should we rebase and merge? The PR looks ok.

@tgodzik tgodzik force-pushed the enum-type-param-source-symbol branch 2 times, most recently from 898a040 to 6c3d7cd Compare February 28, 2025 18:27
@tgodzik tgodzik force-pushed the enum-type-param-source-symbol branch from 6c3d7cd to 62e3af5 Compare February 28, 2025 18:30
@tgodzik
Copy link
Contributor

tgodzik commented Feb 28, 2025

Ok, turns out this needed a bit more work, but should be ok. @rochala can you double check once you are available?

@rochala
Copy link
Contributor Author

rochala commented Mar 11, 2025

Looks good to me

Copy link
Contributor

@tgodzik tgodzik left a comment

Choose a reason for hiding this comment

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

Thanks!

@tgodzik tgodzik merged commit cefa37b into scala:main Mar 11, 2025
29 checks passed
@WojciechMazur WojciechMazur added this to the 3.7.0 milestone Mar 11, 2025
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.

Interactive compiler: go to definition for enum type param
3 participants