You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For a value class V, let U be the underlying type after
erasure. We add to the companion object of V two cast methods:
def underlying2evt$(x0: U): ErasedValueType(V, U)
def evt2underlying$(x0: V): ErasedValueType(U, V)
The casts are used in Erasure to make it typecheck, they are then removed
in ElimErasedValueType (not yet present in this commit). This is
different from the implementation of value classes in Scala 2 (see
SIP-15) which used `asInstanceOf` which does not typecheck.
0 commit comments