Aladdin - Scala Bugtracking
[#112] project: compiler priority: medium category: bug
submitter assigned to status date submitted
Matthias Martin fixed 2003-09-09 12:46:53.0
subject Illegal superclass reference crashes typechecker
code
object T {
  class A {
    class B;
  }
  type C = A#B;
  class D extends C;
}
what happened
The compiler run crashes:
Exception in thread "main" scalac.ApplicationError: TypeRef(ThisType(T),T.A,[])
        at scalac.ast.TreeGen.mkStableId(TreeGen.java:115)
        at scalac.ast.TreeGen.mkRef(TreeGen.java:99)
        at scalac.typechecker.Analyzer.transform(Analyzer.java:2176)
        at scalac.typechecker.Analyzer.transform(Analyzer.java:1725)
        at scalac.typechecker.Analyzer.transformConstrInvocations(Analyzer.java:1564)
        at scalac.typechecker.Analyzer.defineTemplate(Analyzer.java:1125)
        at scalac.typechecker.Analyzer.defineSym(Analyzer.java:995)
        at scalac.typechecker.Analyzer$LazyTreeType.complete(Analyzer.java:638)
        at scalac.symtab.Symbol.info(Symbol.java:700)
        at scalac.symtab.Symbol.initialize(Symbol.java:666)
        at scalac.typechecker.Analyzer.transform(Analyzer.java:1773)
        at scalac.typechecker.Analyzer.transform(Analyzer.java:1744)
        at scalac.typechecker.Analyzer.transformStatSeq(Analyzer.java:1547)
        at scalac.typechecker.Analyzer.transformTemplate(Analyzer.java:1606)
        at scalac.typechecker.Analyzer.transform(Analyzer.java:1820)
        at scalac.typechecker.Analyzer.transform(Analyzer.java:1744)
        at scalac.typechecker.Analyzer.transformStatSeq(Analyzer.java:1547)
        at scalac.typechecker.Analyzer.apply(Analyzer.java:111)
        at scalac.ast.Transformer.apply(Transformer.java:62)
        at scalac.typechecker.Analyzer.apply(Analyzer.java:59)
        at scalac.typechecker.AnalyzerPhase.apply(AnalyzerPhase.java:107)
        at scalac.Global.compile(Global.java:293)
        at scalac.Global.compile(Global.java:266)
        at scalac.Main.main(Main.java:32)
what expected A error message explaining the bug.
[back to overview]
Changes of this bug report
Martin  edited on  2003-09-09 13:34:31.0