scala3 icon indicating copy to clipboard operation
scala3 copied to clipboard

Unexpected type representation reached the compiler backend

Open torgeirsh opened this issue 1 year ago • 1 comments

Compiler version

3.4.2

Minimized code

import scala.compiletime.constValueTuple
import scala.deriving.Mirror

case class Hello(a: Int)
val mirror = summon[Mirror.Of[Hello]]
val test = constValueTuple[mirror.MirroredElemTypes]

Output

[warn] an unexpected type representation reached the compiler backend while compiling <filename>: NoType. If possible, please file a bug on https://github.com/scala/scala3/issues
scala.MatchError: NoType (of class dotty.tools.dotc.core.Types$NoType$)
  | => cat dotty.tools.backend.jvm.BCodeHelpers.dotty$tools$backend$jvm$BCodeHelpers$$typeToTypeKind(BCodeHelpers.scala:764)
        at dotty.tools.backend.jvm.BCodeHelpers$BCInnerClassGen.toTypeKind(BCodeHelpers.scala:202)
	at dotty.tools.backend.jvm.BCodeHelpers$BCInnerClassGen.toTypeKind$(BCodeHelpers.scala:130)
        ... etc

Expectation

Successful compile, or an error message that doesn't tell me to file a bug report. :D

torgeirsh avatar Aug 09 '24 16:08 torgeirsh

Getting the same error here

joan38 avatar Aug 29 '24 06:08 joan38