Repository navigation
Conversation
- scalaVersion 3.3.8 -> 3.9.0; Scala Steward pin 3.3. -> 3.9.
- drop -Yfuture-lazy-vals: rejected by 3.9 ("bad option"), VarHandle-based
lazy vals are the default since 3.8
- KafkaStage: pass the SortedSet ordering with `using` (3.9 no longer
accepts an explicit argument list for the implicit parameter there)
- resource.scala: with 3.9, the NoEnclosingConcurrencyScope given is emitted
returning void, so the BoxedUnit version (linked by code compiled with
3.3) is now provided explicitly via @TargetNAME; keeps MiMa green
(scala/scala3#24653)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- `_` type wildcards -> `?`, `xs: _*` -> `xs*`, `= _` -> `= uninitialized` - remove unused imports/params/pattern vars reported by the new unused checker (`@unused` where the parameter is part of the public API) - remove a written-but-never-read `successCalls` counter in CircuitBreakerStateMachine - `@unchecked` type tests for local classes in flattenPar / groupBy (TODO(scala-3.9)) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
pierscin
marked this pull request as ready for review
October 9, 2026 07:10
adamw
reviewed
Oct 9, 2026
|
|
||
| case FromParent(t) => | ||
| // safe: these values never leave this invocation | ||
| case fp: FromParent @unchecked => |
Member
There was a problem hiding this comment.
hm that's suspicious. Isn't the pool typed with a union type, which should make this work?
Contributor
Author
There was a problem hiding this comment.
New check:
[E092] Pattern Match Unchecked Warning: groupByImpl.scala:150:15
case FromParent(t) =>
the type test for FromParent cannot be checked at runtime because it's a local class
Member
There was a problem hiding this comment.
hm so maybe it should be a private top-level class? or maybe the match can be expressed differently ... it is a proper type, so matching on it should be possible
Contributor
Author
There was a problem hiding this comment.
I'll try to make something readable, but there are 2 problems:
- Inner class with T is shared across JVM and T is erased. It was a bug Pattern matching on a local class is unsound, should emit an unchecked warning scala/scala3#4812
- We can't see method's T when we define class outside of it and when we define it with a type parameter matching on U | FromParent[T] and U can be FromParent[X] for compiler
If it will be worse then we can revert it.
adamw
reviewed
Oct 9, 2026
|
|
||
| case Nested(t) => | ||
| // safe: these values never leave this invocation | ||
| case n: Nested @unchecked => |
Member
There was a problem hiding this comment.
same here ... this shouldn't be unchecked
Contributor
Author
There was a problem hiding this comment.
As above:
[E092] Pattern Match Unchecked Warning: FlowOps.scala:660:15
case Nested(t) =>
the type test for Nested cannot be checked at runtime because it's a local class
adamw
reviewed
Oct 9, 2026
adamw
reviewed
Oct 9, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Needs scala 3.9+ - probably needs new minor version