Aladdin - Scala Bugtracking
[#797] project: compiler priority: low category: bug
submitter assigned to status date submitted
Sean Iulian fixed 2006-11-04 13:56:35.0
subject multi-package/nested/protected super accessor crash
code
// NECESSARY: two files, two packages
// pkg0/HighlighterXXX.scala
package pkg0;
trait HighlighterXXX {
  type Node;
  protected def highlight(node : Node) : Unit;
}
// pkg1/ScalaAutoEditXXX.scala
package pkg1;
import pkg0._;
trait ScalaAutoEditXXX extends HighlighterXXX {
  trait NodeImpl { 
    def self : Node;
    highlight(self);
  }
}
what happened
sean-mcdirmids-computer:~/workspace/test24/src mcdirmid$ ../../scala/build/quick/bin/scalac -log:super -d .\
./bin/ -sourcepath . pkg1/ScalaAutoEditXXX.scala
TREE = pkg1/ScalaAutoEditXXX.scala8:5
Exception in thread "main" scala.tools.nsc.symtab.Types$TypeError: type mismatch;
found   : HighlighterXXX.this.Node
required: scala.Nothing
	at scala.tools.nsc.typechecker.Contexts$Context.error(Contexts.scala:252)
	at scala.tools.nsc.typechecker.Infer$Inferencer.error(Infer.scala:245)
	at scala.tools.nsc.typechecker.Infer$Inferencer.typeError(Infer.scala:254)
	at scala.tools.nsc.typechecker.Infer$Inferencer.typeErrorTree(Infer.scala:263)
	at scala.tools.nsc.typechecker.Typers$Typer.adapt(Typers.scala:633)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2110)
	at scala.tools.nsc.typechecker.Typers$Typer.typedArg(Typers.scala:1226)
	at scala.tools.nsc.typechecker.Typers$Typer$$anonfun$52.apply(Typers.scala:1243)
	at scala.tools.nsc.typechecker.Typers$Typer$$anonfun$52.apply(Typers.scala:1243)
	at scala.List$.map2(List.scala:271)
	at scala.tools.nsc.typechecker.Typers$Typer.typedArgs(Typers.scala:1243)
	at scala.tools.nsc.typechecker.Typers$Typer.typedApply(Typers.scala:1270)
	at scala.tools.nsc.typechecker.Typers$Typer.typed1(Typers.scala:1971)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2108)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2151)
	at scala.tools.nsc.typechecker.Typers$Typer.transformedOrTyped(Typers.scala:2190)
	at scala.tools.nsc.typechecker.Typers$Typer.typedDefDef(Typers.scala:1016)
	at scala.tools.nsc.typechecker.Typers$Typer.typed1(Typers.scala:1748)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2108)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2140)
	at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.makeAccessor(SuperAccessors.scala:197)
	at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.transform(SuperAccessors.scala:86)
	at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.transform(SuperAccessors.scala:140)
	at scala.tools.nsc.ast.Trees$Transformer$$anonfun$30$$anonfun$31.apply(Trees.scala:1131)
	at scala.tools.nsc.ast.Trees$Transformer$$anonfun$30$$anonfun$31.apply(Trees.scala:1131)
	at scala.tools.nsc.ast.Trees$Transformer.atOwner(Trees.scala:1138)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:32)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:26)
	at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.atOwner(SuperAccessors.scala:158)
	at scala.tools.nsc.ast.Trees$Transformer$$anonfun$30.apply(Trees.scala:1131)
	at scala.tools.nsc.ast.Trees$Transformer$$anonfun$30.apply(Trees.scala:1130)
	at scala.List$.loop$0(List.scala:238)
	at scala.List$.mapConserve(List.scala:255)
	at scala.tools.nsc.ast.Trees$Transformer.transformStats(Trees.scala:1130)
	at scala.tools.nsc.ast.Trees$Transformer.transform(Trees.scala:1050)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.scala$tools$nsc$transform$TypingTransformers$\
TypingTransformer$$super$transform(TypingTransformers.scala:43)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer$$anonfun$0.apply(TypingTransformers.scala:43)\

	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer$$anonfun$0.apply(TypingTransformers.scala:43)\

	at scala.tools.nsc.ast.Trees$Transformer.atOwner(Trees.scala:1138)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:32)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:26)
	at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.atOwner(SuperAccessors.scala:158)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.transform(TypingTransformers.scala:43)
	at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.transform(SuperAccessors.scala:68)
	at scala.tools.nsc.ast.Trees$Transformer.transformTemplate(Trees.scala:1118)
	at scala.tools.nsc.ast.Trees$Transformer$$anonfun$17.apply(Trees.scala:1018)
	at scala.tools.nsc.ast.Trees$Transformer$$anonfun$17.apply(Trees.scala:1017)
	at scala.tools.nsc.ast.Trees$Transformer.atOwner(Trees.scala:1138)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:32)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:26)
	at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.atOwner(SuperAccessors.scala:158)
	at scala.tools.nsc.ast.Trees$Transformer.transform(Trees.scala:1016)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.transform(TypingTransformers.scala:45)
	at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.transform(SuperAccessors.scala:63)
	at scala.tools.nsc.ast.Trees$Transformer$$anonfun$30.apply(Trees.scala:1132)
	at scala.tools.nsc.ast.Trees$Transformer$$anonfun$30.apply(Trees.scala:1130)
	at scala.List$.loop$0(List.scala:238)
	at scala.List$.mapConserve(List.scala:255)
	at scala.tools.nsc.ast.Trees$Transformer.transformStats(Trees.scala:1130)
	at scala.tools.nsc.ast.Trees$Transformer.transform(Trees.scala:1050)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.scala$tools$nsc$transform$TypingTransformers$\
TypingTransformer$$super$transform(TypingTransformers.scala:43)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer$$anonfun$0.apply(TypingTransformers.scala:43)\

	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer$$anonfun$0.apply(TypingTransformers.scala:43)\

	at scala.tools.nsc.ast.Trees$Transformer.atOwner(Trees.scala:1138)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:32)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:26)
	at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.atOwner(SuperAccessors.scala:158)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.transform(TypingTransformers.scala:43)
	at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.transform(SuperAccessors.scala:68)
	at scala.tools.nsc.ast.Trees$Transformer.transformTemplate(Trees.scala:1118)
	at scala.tools.nsc.ast.Trees$Transformer$$anonfun$17.apply(Trees.scala:1018)
	at scala.tools.nsc.ast.Trees$Transformer$$anonfun$17.apply(Trees.scala:1017)
	at scala.tools.nsc.ast.Trees$Transformer.atOwner(Trees.scala:1138)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:32)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:26)
	at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.atOwner(SuperAccessors.scala:158)
	at scala.tools.nsc.ast.Trees$Transformer.transform(Trees.scala:1016)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.transform(TypingTransformers.scala:45)
	at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.transform(SuperAccessors.scala:63)
	at scala.tools.nsc.ast.Trees$Transformer$$anonfun$30.apply(Trees.scala:1132)
	at scala.tools.nsc.ast.Trees$Transformer$$anonfun$30.apply(Trees.scala:1130)
	at scala.List$.loop$0(List.scala:238)
	at scala.List$.mapConserve(List.scala:255)
	at scala.tools.nsc.ast.Trees$Transformer.transformStats(Trees.scala:1130)
	at scala.tools.nsc.ast.Trees$Transformer$$anonfun$16.apply(Trees.scala:1013)
	at scala.tools.nsc.ast.Trees$Transformer$$anonfun$16.apply(Trees.scala:1013)
	at scala.tools.nsc.ast.Trees$Transformer.atOwner(Trees.scala:1138)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:32)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.atOwner(TypingTransformers.scala:26)
	at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.atOwner(SuperAccessors.scala:158)
	at scala.tools.nsc.ast.Trees$Transformer.transform(Trees.scala:1012)
	at scala.tools.nsc.transform.TypingTransformers$TypingTransformer.transform(TypingTransformers.scala:45)
	at scala.tools.nsc.typechecker.SuperAccessors$SuperAccTransformer.transform(SuperAccessors.scala:147)
	at scala.tools.nsc.ast.Trees$Transformer.transformUnit(Trees.scala:1133)
	at scala.tools.nsc.transform.Transform$Phase.apply(Transform.scala:30)
	at scala.tools.nsc.Global$GlobalPhase.applyPhase(Global.scala:219)
	at scala.tools.nsc.Global$GlobalPhase$$anonfun$1.apply(Global.scala:208)
	at scala.tools.nsc.Global$GlobalPhase$$anonfun$1.apply(Global.scala:208)
	at scala.Iterator$class.foreach(Iterator.scala:316)
	at scala.collection.mutable.ListBuffer$$anon$0.foreach(ListBuffer.scala:244)
	at scala.tools.nsc.Global$GlobalPhase.run(Global.scala:208)
	at scala.tools.nsc.Global$Run.compileSources(Global.scala:473)
	at scala.tools.nsc.Global$Run.compile(Global.scala:542)
	at scala.tools.nsc.Main$.process(Main.scala:74)
	at scala.tools.nsc.Main$.main(Main.scala:96)
	at scala.tools.nsc.Main.main(Main.scala):
what expected
[back to overview]
Changes of this bug report
Iulian  edited on  2006-11-09 17:07:16.0