Backport "Fixes #25947, #11043: Avoid JavaArrayType in synthesized classOf for structural calls" to 3.3 LTS - #1061
Open
tgodzik wants to merge 2 commits into
Open
Backport "Fixes #25947, #11043: Avoid JavaArrayType in synthesized classOf for structural calls" to 3.3 LTS#1061tgodzik wants to merge 2 commits into
tgodzik wants to merge 2 commits into
Conversation
tgodzik
force-pushed
the
backport-lts-3.3-26028
branch
4 times, most recently
from
August 7, 2026 15:49
35e57ce to
e7da0a8
Compare
tgodzik
force-pushed
the
backport-lts-3.3-26256
branch
from
August 7, 2026 15:55
da12e75 to
890ee2f
Compare
…assOf for structural calls (scala#26028) When a structural method has an `Array[T]` parameter, `Dynamic` synthesized the runtime `applyDynamic` call with `clsOf(JavaArrayType(T))` for the parameter-class array. `JavaArrayType` is not a Scala source type and has no TASTy encoding, so the pickler crashed with a `MatchError` on the class-literal constant. Convert `JavaArrayType(T)` back to the Scala `Array[T]` form before passing it to `clsOf`. The two forms re-erase to the same JVM array class, so the runtime reflective lookup is unchanged. Fixes scala#25947 scala#11043 ## How much have you relied on LLM-based tools in this contribution? Extensively, but it's a small fix. ## How was the solution tested? New automated tests (including the issue's reproducer, if applicable) --------- Co-authored-by: Claude <noreply@anthropic.com> [Cherry-picked 4a99a48]
tgodzik
force-pushed
the
backport-lts-3.3-26028
branch
from
August 7, 2026 15:56
e7da0a8 to
944d825
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backports scala#26028 to the 3.3.9.
PR submitted by the release tooling.