Closed
Description
Following yesterday's Core Meeting Decision (#22493 (comment)), the semantics of value classes in Scala 2 and Scala 3 are different (only changes in equals
and hashCode
). When compiling the common subset of the scala 3 stdlib (scala2 stdlib), we need to recover the old semantics. One way to do it, that doesn't require a compiler change is to define manually the equals
and hashCode
methods (which is possible in Scala 3, see #22494). I'm not a fan of it is very error-prone. A second approach is to recover the old semantics under the -Ycompile-scala2-library
, which is the one I'm adopting.