I have a project that contains a lot of compiler warning of the format "discarded non-Unit value of type ...":
[Warn] /home/peng/git/shapesafe/prover-commons/module/core/src/main/scala/ai/acyclic/prover/commons/Same.scala:165:27: discarded non-Unit value of type Option[(ai.acyclic.prover.commons.function.Thunk[V], Long)]
[Warn] /home/peng/git/shapesafe/prover-commons/module/core/src/main/scala/ai/acyclic/prover/commons/diff/StringDiff.scala:159:16: discarded non-Unit value of type Any
[Warn] /home/peng/git/shapesafe/prover-commons/module/core/src/main/scala/ai/acyclic/prover/commons/function/HasMorphism.scala:94:24: Top-level wildcard is not allowed
[Warn] /home/peng/git/shapesafe/prover-commons/module/core/src/main/scala/ai/acyclic/prover/commons/graph/local/Local.scala:18:15: discarded non-Unit value of type example._Arrow <:< ai.acyclic.prover.commons.graph.local.Local.Tree._Arrow
[Warn] /home/peng/git/shapesafe/prover-commons/module/core/src/main/scala/ai/acyclic/prover/commons/graph/local/Local.scala:7:15: private method compileTimeCheck in object Local is never used
[Warn] /home/peng/git/shapesafe/prover-commons/module/core/src/main/scala/ai/acyclic/prover/commons/graph/local/ops/AnyGraphUnary.scala:78:52: private default argument in object DepthFirst is never used
[Warn] /home/peng/git/shapesafe/prover-commons/module/core/src/main/scala/ai/acyclic/prover/commons/graph/local/ops/UpperSemilatticeUnary.scala:54:12: discarded non-Unit value of type ai.acyclic.prover.commons.graph.local.LocalEngine._GraphK[UpperSemilatticeUnary.this.ArgLaw]{type Value = UpperSemilatticeUnary.this.ArgV}
They were linting rules introduced in Scala 2.13, cannot suppressed, and may become an error in Scala 3.
Can scalafix automatically fix them?