Aladdin - Scala Bugtracking
[#838] project: compiler priority: low category: bug
submitter assigned to status date submitted
Sean Martin fixed 2006-11-25 13:58:29.0
subject no-symbol has no owner crash
code
// see test/pending/neg/bug112506A.scala
package test;
import scala.collection.immutable._;
import scala.collection.mutable._;
trait TypeManagerXXX {
  trait TypedNode;
  type Node;
}
trait ScalaTyperXXX extends TypeManagerXXX {
  private var typed : Node = null;
  private val dependMap = new HashMap[String,ListSet[TypedNode]]; 
  override def lookupEntry(name: String): String = {
    val set = dependMap.get(name) match {
    case Some(set) => set;
    case None => new ListSet[Node]
    }
    dependMap.update(name, set + typed);
    throw new Error;
  }
}
what happened
Probably crashing while making the type error:

sean-mcdirmid:~/workspace/lampion/src mcdirmid$ ../../scala/build/quick/bin/scalac -sourcepath . -d ../bin \
lampion/scalax/ScalaTyperXXX.scala
Exception in thread "main" java.lang.Error: no-symbol does not have owner
	at scala.tools.nsc.symtab.Symbols$NoSymbol$.owner(Symbols.scala:1272)
	at scala.tools.nsc.symtab.Symbols$Symbol.defString(Symbols.scala:998)
	at scala.tools.nsc.symtab.Scopes$Scope$$anonfun$3.apply(Scopes.scala:266)
	at scala.tools.nsc.symtab.Scopes$Scope$$anonfun$3.apply(Scopes.scala:266)
	at scala.List.map(List.scala:672)
	at scala.tools.nsc.symtab.Scopes$Scope.mkString(Scopes.scala:266)
	at scala.tools.nsc.symtab.Types$CompoundType.toString(Types.scala:807)
	at java.lang.String.valueOf(String.java:2577)
	at java.lang.StringBuffer.append(StringBuffer.java:220)
	at scala.tools.nsc.typechecker.Typers$Typer.typedSelect$0(Typers.scala:1664)
	at scala.tools.nsc.typechecker.Typers$Typer.typed1(Typers.scala:2137)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2222)
	at scala.tools.nsc.typechecker.Typers$Typer.typed1(Typers.scala:2067)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2222)
	at scala.tools.nsc.typechecker.Typers$Typer.typedArg(Typers.scala:1294)
	at scala.tools.nsc.typechecker.Typers$Typer$$anonfun$52.apply(Typers.scala:1311)
	at scala.tools.nsc.typechecker.Typers$Typer$$anonfun$52.apply(Typers.scala:1311)
	at scala.List$.map2(List.scala:277)
	at scala.tools.nsc.typechecker.Typers$Typer.typedArgs(Typers.scala:1311)
	at scala.tools.nsc.typechecker.Typers$Typer.typedApply(Typers.scala:1346)
	at scala.tools.nsc.typechecker.Typers$Typer.tryTypedApply$0(Typers.scala:1571)
	at scala.tools.nsc.typechecker.Typers$Typer.typed1(Typers.scala:2076)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2222)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2254)
	at scala.tools.nsc.typechecker.Typers$Typer.typedStat$0(Typers.scala:1267)
	at scala.tools.nsc.typechecker.Typers$Typer$$anonfun$48.apply(Typers.scala:1288)
	at scala.tools.nsc.typechecker.Typers$Typer$$anonfun$48.apply(Typers.scala:1288)
	at scala.List$.loop$0(List.scala:244)
	at scala.List$.mapConserve(List.scala:261)
	at scala.List$.loop$0(List.scala:248)
	at scala.List$.mapConserve(List.scala:261)
	at scala.tools.nsc.typechecker.Typers$Typer.typedStats(Typers.scala:1288)
	at scala.tools.nsc.typechecker.Typers$Typer.typedBlock(Typers.scala:1131)
	at scala.tools.nsc.typechecker.Typers$Typer.typed1(Typers.scala:1879)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2222)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2265)
	at scala.tools.nsc.typechecker.Typers$Typer.transformedOrTyped(Typers.scala:2304)
	at scala.tools.nsc.typechecker.Typers$Typer.typedDefDef(Typers.scala:1062)
	at scala.tools.nsc.typechecker.Typers$Typer.typed1(Typers.scala:1855)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2222)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2254)
	at scala.tools.nsc.typechecker.Typers$Typer.typedStat$0(Typers.scala:1267)
	at scala.tools.nsc.typechecker.Typers$Typer$$anonfun$48.apply(Typers.scala:1288)
	at scala.tools.nsc.typechecker.Typers$Typer$$anonfun$48.apply(Typers.scala:1288)
	at scala.List$.loop$0(List.scala:244)
	at scala.List$.mapConserve(List.scala:261)
	at scala.List$.loop$0(List.scala:248)
	at scala.List$.mapConserve(List.scala:261)
	at scala.List$.loop$0(List.scala:248)
	at scala.List$.mapConserve(List.scala:261)
	at scala.tools.nsc.typechecker.Typers$Typer.typedStats(Typers.scala:1288)
	at scala.tools.nsc.typechecker.Typers$Typer.typedTemplate(Typers.scala:914)
	at scala.tools.nsc.typechecker.Typers$Typer.typedClassDef(Typers.scala:819)
	at scala.tools.nsc.typechecker.Typers$Typer.typed1(Typers.scala:1846)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2222)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2254)
	at scala.tools.nsc.typechecker.Typers$Typer.typedStat$0(Typers.scala:1267)
	at scala.tools.nsc.typechecker.Typers$Typer$$anonfun$48.apply(Typers.scala:1288)
	at scala.tools.nsc.typechecker.Typers$Typer$$anonfun$48.apply(Typers.scala:1288)
	at scala.List$.loop$0(List.scala:244)
	at scala.List$.mapConserve(List.scala:261)
	at scala.List$.loop$0(List.scala:248)
	at scala.List$.mapConserve(List.scala:261)
	at scala.List$.loop$0(List.scala:248)
	at scala.List$.mapConserve(List.scala:261)
	at scala.List$.loop$0(List.scala:248)
	at scala.List$.mapConserve(List.scala:261)
	at scala.tools.nsc.typechecker.Typers$Typer.typedStats(Typers.scala:1288)
	at scala.tools.nsc.typechecker.Typers$Typer.typed1(Typers.scala:1842)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2222)
	at scala.tools.nsc.typechecker.Typers$Typer.typed(Typers.scala:2254)
	at scala.tools.nsc.typechecker.Analyzer$typerFactory$$anon$1.apply(Analyzer.scala:38)
	at scala.tools.nsc.Global$GlobalPhase.applyPhase(Global.scala:220)
	at scala.tools.nsc.Global$GlobalPhase$$anonfun$1.apply(Global.scala:209)
	at scala.tools.nsc.Global$GlobalPhase$$anonfun$1.apply(Global.scala:209)
	at scala.Iterator$class.foreach(Iterator.scala:341)
	at scala.collection.mutable.ListBuffer$$anon$0.foreach(ListBuffer.scala:244)
	at scala.tools.nsc.Global$GlobalPhase.run(Global.scala:209)
	at scala.tools.nsc.Global$Run.compileSources(Global.scala:475)
	at scala.tools.nsc.Global$Run.compile(Global.scala:547)
	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)
sean-mcdirmid:~/workspace/lampion/src mcdirmid$
what expected
[back to overview]
Changes of this bug report
Martin  edited on  2006-12-01 10:59:32.0