From e8b450d51d3db4f6fd181910a83799f2ebd9ef59 Mon Sep 17 00:00:00 2001 From: Eugene Vigdorchik Date: Mon, 3 Jan 2011 20:36:01 +0000 Subject: Temp rollback. --- src/compiler/scala/tools/nsc/typechecker/Namers.scala | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/compiler/scala/tools/nsc/typechecker/Namers.scala b/src/compiler/scala/tools/nsc/typechecker/Namers.scala index fc19188d9e..5e03c048c7 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Namers.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Namers.scala @@ -47,9 +47,7 @@ trait Namers { self: Analyzer => // synthetic `copy' (reps `apply', `unapply') methods are added. To compute // their signatures, the corresponding ClassDef is needed. // During naming, for each case class module symbol, the corresponding ClassDef - // is stored in this map. The map is cleared lazily, i.e. when the new symbol - // is created with the same name, the old one (if present) is wiped out, or the - // entry is deleted when it is used and no longer needed. + // is stored in this map. private[typechecker] val caseClassOfModuleClass = new HashMap[Symbol, ClassDef] // Default getters of constructors are added to the companion object in the @@ -61,6 +59,7 @@ trait Namers { self: Analyzer => private[typechecker] val classAndNamerOfModule = new HashMap[Symbol, (ClassDef, Namer)] def resetNamer() { + caseClassOfModuleClass.clear classAndNamerOfModule.clear } @@ -204,7 +203,6 @@ trait Namers { self: Analyzer => updatePosFlags(c, tree.pos, tree.mods.flags) setPrivateWithin(tree, c, tree.mods) } else { - caseClassOfModuleClass -= c var sym = context.owner.newClass(tree.pos, tree.name) sym = sym.setFlag(tree.mods.flags | inConstructorFlag) sym = setPrivateWithin(tree, sym, tree.mods) -- cgit v1.2.3