Closed
Description
I'm on vacation and don't have time to really think about this or dig deeper, but since it's a regression I thought I should report it promptly.
//> using scala 3.5.0-RC2
//> using option -Wunused:imports
def test =
import Ordering.Implicits.{given Ordering[?]}
summon[Ordering[Seq[Int]]]
on 3.5.0-RC2 this gives:
[warn] unused import
[warn] import Ordering.Implicits.{given Ordering[?]}
[warn] ^^^^^^^^^^^^^^^^^
but the import is definitely used — the code doesn't compile without it
note that I can write import Ordering.Implicits.seqOrdering
instead, which is better code anyway, the original code is admittedly peculiar (I don't remember what I might have been thinking when I wrote it)
minimized from https://github.com/SethTisue/Project-Euler/blob/main/src/test/scala/54.scala