Closed
Description
Compiler version
3.7.0-RC1-bin-20250306-73ba485-NIGHTLY
Minimized code
With -Wunused:unsafe-warn-patvars
enabled:
def foo: (Int, String) = (1, "foo")
lazy val (i, s) = foo
Output
-- [E198] Unused Symbol Warning: /Users/matt/scala3.7-nightly-unused/src/main/scala/example/Test.scala:2:10 ------------
2 |lazy val (i, s) = foo
| ^
| unused pattern variable
-- [E198] Unused Symbol Warning: /Users/matt/scala3.7-nightly-unused/src/main/scala/example/Test.scala:2:13 ------------
2 |lazy val (i, s) = foo
| ^
| unused pattern variable
Expectation
The values should not be reported unused because they're public