estatico / scala-newtype

NewTypes for Scala with no runtime overhead
Apache License 2.0
540 stars 31 forks source link

Remove superfluous refinement from Base type #27

Closed carymrobbins closed 6 years ago

carymrobbins commented 6 years ago

Seems without the refinement we get runtime cast exceptions; the compiler seems to be trying to cast to the Tag trait instead of allowing it to be Object -

java.lang.ClassCastException: java.lang.String cannot be cast to io.estatico.newtype.macros.NewTypeMacrosTest$X0$Types$1$Tag