Skip to content

Conversation

@tgodzik
Copy link

@tgodzik tgodzik commented Nov 18, 2025

Backports scala#24380 to the 3.3.7.

PR submitted by the release tooling.
[skip ci]

smarter and others added 4 commits November 18, 2025 10:48
Previously, the valueOf inline call succeeded (because the ValueOf synthesizer
calls `tpd.ref` which calls `tpd.singleton`), leading to an invalid tree which
crashed in the backend with: "assertion failed: Cannot create ClassBType from
NoSymbol".

Fixed by throwing a TypeError from `tpd.singleton`, unfortunatley this means
tests/neg/i8623.scala gets a worse error message because the implicit search
fails early, but arguably this is more correct.
Previously, the valueOf inline call succeeded (because the ValueOf synthesizer
calls `tpd.ref` which calls `tpd.singleton`), leading to an invalid tree which
crashed in the backend with: "assertion failed: Cannot create ClassBType from
NoSymbol".

Fixed by throwing a TypeError from `tpd.singleton`, unfortunatley this means
tests/neg/i8623.scala gets a worse error message because the implicit search
fails early, but arguably this is more correct.

[Cherry-picked 6e4b0a0][modified]
@tgodzik tgodzik closed this Nov 18, 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.

3 participants