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

AssertionError in compiler #149

Open
OlegYch opened this issue Apr 10, 2020 · 0 comments
Open

AssertionError in compiler #149

OlegYch opened this issue Apr 10, 2020 · 0 comments

Comments

@OlegYch
Copy link
Contributor

OlegYch commented Apr 10, 2020

https://scastie.scala-lang.org/OlegYch/BlI4CHhuSGOBXIQdlRJcwg/2

import com.softwaremill.macwire._

case class Config(redis: Int)
case class B(redis: Int)
trait MacWireComponents2 {
  def int: Int
  lazy val config = wire[Config]
  lazy val b   = {
    val redis = config.redis
    B(redis)
  }
}

throws

[error] java.lang.AssertionError: assertion failed:
[error]   transformCaseApply: name = config tree = config / class scala.reflect.internal.Trees$Ident
[error]      while compiling: MacWireComponents2.scala
[error]         during phase: refchecks
[error]      library version: version 2.13.1
[error]     compiler version: version 2.13.1

adding explicit type to config works around it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant