Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"ClassBType.info not yet assigned" error with Scala 2.13.0-RC1 #11524

Open
xuwei-k opened this issue May 10, 2019 · 3 comments

Comments

Projects
None yet
5 participants
@xuwei-k
Copy link

commented May 10, 2019

[error] Error while emitting CofreeTest.scala
[error] <error> (of class scala.reflect.internal.Types$ErrorType$)
[error] Error while emitting CofreeTest.scala
[error] assertion failed: ClassBType.info not yet assigned: Lscalaz/CofreeTest$LazyDefns$1$1;
[warn] 402 warnings found
[error] two errors found
[error] (testsJVM / Test / compileIncremental) Compilation failed

@SethTisue SethTisue added this to the 2.13.0-RC2 milestone May 10, 2019

@lrytz

This comment has been minimized.

Copy link
Member

commented May 10, 2019

Can reproduce locally

@lrytz

This comment has been minimized.

Copy link
Member

commented May 10, 2019

This seems to be an interaction with scala/scala#6050.

I just attached the debugger to the 2.13.0-RC1 compiler when running. Here's the tree that reaches the backend. Note the error type, which is causing the warning https://github.com/scala/scala/blob/v2.13.0-RC1/src/compiler/scala/tools/nsc/backend/jvm/BTypesFromSymbols.scala#L185.

object CofreeTest extends Object {
  final <static> <artifact> def $anonfun$new$1(lazyDefns$1$1: scalaz.CofreeTest$LazyDefns$1$1): scalaz.Order = lazyDefns$1$1.<rec$1: error>();
  def <init>(): scalaz.CofreeTest.type = {
    CofreeTest.super.<init>();
    scala.Predef.implicitly({
      final <synthetic> val lazyDefns$1: scalaz.CofreeTest$LazyDefns$1$1 = new scalaz.CofreeTest$LazyDefns$1$1();
      scalaz.this.Cofree.cofreeOrder(scalaz.std.anyVal.intInstance().$asInstanceOf[scalaz.Order](), {
        $anonfun(lazyDefns$1)
      })
    });
    ()
  }
}

The by-name implicit is https://github.com/xuwei-k/scalaz/blob/2201a647b81100df72ff74ab1d150e005339adf6/core/src/main/scala-2.13+/scalaz/CofreeInstancesVersionSpecific.scala#L14

To reproduce

A minimization would be helpful.. But @milessabin maybe you can take a look anyway?

@adriaanm adriaanm modified the milestones: 2.13.0-RC2, 2.13.1 May 10, 2019

@milessabin

This comment has been minimized.

Copy link

commented May 13, 2019

I'll try and find time in the next day or two. @xuwei-k a minimization would be really helpful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.