Aladdin - Scala Bugtracking
[#513] project: compiler priority: medium category: bug
submitter assigned to status date submitted
Sean Martin fixed 2006-01-13 15:32:22.0
subject error with sourcepath?
code
Two files:

"class XXX;" in ./xxx/XXX.scala

and

"class YYY extends XXX;" in ./xxx/YYY.scala

Compile from .

scala2 -sourcepath xxx xxx/YYY.scala
what happened
crash:

Exception in thread "main" java.lang.Error: assertion failed
        at scala.Predef$.assert(Predef.scala:139)
        at scala.tools.nsc.symtab.Symbols$TermSymbol.setAlias(Symbols.scala:817)
        at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.transform(SuperAccessors.scala:57)
        at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.transform(SuperAccessors.scala:67)
        at scala.tools.nsc.ast.Trees$Transformer$$anonfun16.apply(Trees.scala:961)
        at scala.tools.nsc.ast.Trees$Transformer$$anonfun16.apply(Trees.scala:960)
        at scala.tools.nsc.ast.Trees$Transformer.atOwner(Trees.scala:1062)
        at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.atOwner(SuperAccessors.scala:78)
        at scala.tools.nsc.ast.Trees$Transformer.transform(Trees.scala:959)
        at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.transform(SuperAccessors.scala:73)
        at scala.tools.nsc.ast.Trees$Transformer$$anonfun19.apply(Trees.scala:1040)
        at scala.tools.nsc.ast.Trees$Transformer$$anonfun19.apply(Trees.scala:1040)
        at scala.List$.loop0(List.scala:241)
        at scala.List$.mapConserve(List.scala:258)
        at scala.tools.nsc.ast.Trees$Transformer.transformTrees(Trees.scala:1040)
        at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.transform(SuperAccessors.scala:43)
        at scala.tools.nsc.ast.Trees$Transformer.transformTemplate(Trees.scala:1042)
        at scala.tools.nsc.ast.Trees$Transformer$$anonfun13.apply(Trees.scala:948)
        at scala.tools.nsc.ast.Trees$Transformer$$anonfun13.apply(Trees.scala:948)
        at scala.tools.nsc.ast.Trees$Transformer.atOwner(Trees.scala:1062)
        at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.atOwner(SuperAccessors.scala:78)
        at scala.tools.nsc.ast.Trees$Transformer.transform(Trees.scala:947)
        at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.transform(SuperAccessors.scala:73)
        at scala.tools.nsc.ast.Trees$Transformer$$anonfun25.apply(Trees.scala:1056)
        at scala.tools.nsc.ast.Trees$Transformer$$anonfun25.apply(Trees.scala:1054)
        at scala.List$.loop0(List.scala:241)
        at scala.List$.mapConserve(List.scala:258)
        at scala.tools.nsc.ast.Trees$Transformer.transformStats(Trees.scala:1054)
        at scala.tools.nsc.ast.Trees$Transformer$$anonfun12.apply(Trees.scala:944)
        at scala.tools.nsc.ast.Trees$Transformer$$anonfun12.apply(Trees.scala:944)
        at scala.tools.nsc.ast.Trees$Transformer.atOwner(Trees.scala:1062)
        at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.atOwner(SuperAccessors.scala:78)
        at scala.tools.nsc.ast.Trees$Transformer.transform(Trees.scala:943)
        at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.transform(SuperAccessors.scala:73)
        at scala.tools.nsc.ast.Trees$Transformer.transformUnit(Trees.scala:1057)
        at scala.tools.nsc.transform.Transform$Phase.apply(Transform.scala:22)
        at scala.tools.nsc.Global$GlobalPhase.applyPhase(Global.scala:180)
        at scala.tools.nsc.Global$GlobalPhase$$anonfun1.apply(Global.scala:169)
        at scala.tools.nsc.Global$GlobalPhase$$anonfun1.apply(Global.scala:169)
        at scala.Iterator$class.foreach(Iterator.scala:262)
        at scala.List$$anon1.foreach(List.scala:474)
        at scala.tools.nsc.Global$GlobalPhase.run(Global.scala:169)
        at scala.tools.nsc.Global$Run.compileSources(Global.scala:378)
        at scala.tools.nsc.Global$Run.compile(Global.scala:446)
        at scala.tools.nsc.Main$.process(Main.scala:57)
        at scala.tools.nsc.Main$.main(Main.scala:69)
        at scala.tools.nsc.Main.main(Main.scala)
what expected Should be able to locate "XXX.scala" in directory xxx because sourcepath is set. This might be the case, but for some reason its crashing at setAlias. I get this crash a lot in the plugin also, but for resident compilation reasons.
[back to overview]
Changes of this bug report
Sean  edited on  2006-01-13 15:46:15.0
Sean  edited on  2006-01-13 16:00:47.0
Martin  edited on  2006-01-20 18:35:48.0