Closed
Description
Compiler version
Scala 3.6.2 with scalacOptions "-Wunused:imports"
Minimized code
import scala.compiletime.deferred
class Context
trait Foo:
given context: Context = deferred
Output
Scala compiler returns a warning
unused import import scala.compiletime.deferred
The incorrect warning results in misleading highlighting in IntelliJ IDEA when compiler-based highlighting is enabled
Expectation
The compiler should not return an "unused import" warning for scala.compiletime.deferred
, as it is clearly used in the code