In Scala 2, there is a function TypeApi#erasure described as follows
The erased type corresponding to this type after
all transformations from Scala to Java have been performed.
How to get erased Type for a given TypeRepr in Scala 3?
In Scala 2, there is a function TypeApi#erasure described as follows
The erased type corresponding to this type after
all transformations from Scala to Java have been performed.
How to get erased Type for a given TypeRepr in Scala 3?
I have also asked this question on dotty Gitter and it came out, that currently there is no available API for getting erased types. Then I created a dotty feature request in which you can find possible workarounds.