-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Closed
Description
scalac compiles but dotc crashes.
$ dotc -version
Dotty compiler version 0.5.0-bin-SNAPSHOT-git-4fefb64 -- Copyright 2002-2017, LAMP/EPFL
$ dotc abc.scala
-- [E006] Unbound Identifier Error: abc.scala:5:5 ------------------------------
5 | @annot class Silly {}
| ^^^^^
| not found: type annot
longer explanation available when compiling with `-explain`
exception occurred while typechecking abc.scala
exception occurred while compiling abc.scala
Exception in thread "main" java.lang.AssertionError: assertion failed: dotty.tools.dotc.core.Scopes$MutableScope@3c7f66c4
at dotty.DottyPredef$.assertFail(DottyPredef.scala:39)
at dotty.tools.dotc.typer.NamerContextOps.denotNamed(Namer.scala:51)
at dotty.tools.dotc.typer.Typer.loop$1(Typer.scala:271)
at dotty.tools.dotc.typer.Typer.findRef$1(Typer.scala:334)
at dotty.tools.dotc.typer.Typer.op$1(Typer.scala:353)
at dotty.tools.dotc.typer.Typer.typedIdent(Typer.scala:102)
at dotty.tools.dotc.typer.Typer.typedNamed$1(Typer.scala:1622)
at dotty.tools.dotc.typer.Typer.typedUnadapted(Typer.scala:1689)
at dotty.tools.dotc.typer.Typer.op$40(Typer.scala:1707)
at dotty.tools.dotc.typer.Typer.typed(Typer.scala:1703)
at dotty.tools.dotc.typer.Typer.typedType(Typer.scala:1766)
at dotty.tools.dotc.typer.Typer.op$6(Typer.scala:475)
at dotty.tools.dotc.typer.Typer.typedNew(Typer.scala:456)
at dotty.tools.dotc.typer.Typer.typedUnnamed$1(Typer.scala:1645)
at dotty.tools.dotc.typer.Typer.typedUnadapted(Typer.scala:1690)
at dotty.tools.dotc.typer.Typer.op$40(Typer.scala:1707)
at dotty.tools.dotc.typer.Typer.typed(Typer.scala:1703)
at dotty.tools.dotc.typer.Typer.typedExpr(Typer.scala:1764)
at dotty.tools.dotc.typer.Typer.typeSelectOnTerm$1(Typer.scala:397)
<snipped>
$ cat abc.scala
object test {
class annot extends scala.annotation.Annotation
def foo = {
def bar(i: Int): Int = i
@annot class Silly {}
bar(5)
}
}
Metadata
Metadata
Assignees
Labels
No labels