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
The following throws a VerifyError (Tested with 3.0.0-M3)
import scala.reflect.ClassTag
@main def run = println(Foo)
abstract class Bar[T](implicit val thisClassTag: ClassTag[T])
class Foo
object Foo extends Bar[Foo]
Alternatives tried:
Changing abstract class Bar[T](implicit val thisClassTag: ClassTag[T]) to abstract class Bar[T: ClassTag]{ val thisClassTag: ClassTag[T] = implicitly[ClassTag[T]] } works
Changing object Foo extends Bar[Foo] to object Foo extends Bar()(classTag[Foo]) works
Summoning an implicit of a different class works (only ClassTag specifically seems to be affected)
Using the ClassTag of anything other than the companion class works (object Foo extends Bar[Foo2] seems fine)
The text was updated successfully, but these errors were encountered:
Uh oh!
There was an error while loading. Please reload this page.
The following throws a
VerifyError
(Tested with 3.0.0-M3)Alternatives tried:
abstract class Bar[T](implicit val thisClassTag: ClassTag[T])
toabstract class Bar[T: ClassTag]{ val thisClassTag: ClassTag[T] = implicitly[ClassTag[T]] }
worksobject Foo extends Bar[Foo]
toobject Foo extends Bar()(classTag[Foo])
worksClassTag
specifically seems to be affected)object Foo extends Bar[Foo2]
seems fine)The text was updated successfully, but these errors were encountered: