From 6f05acaa43d8aa036e26f68937e71dbae60bb5b4 Mon Sep 17 00:00:00 2001 From: Jason Zaugg Date: Sun, 9 Feb 2014 18:41:16 +0100 Subject: Optimization: use AnyRef map for Namer -> Typer tree handoff And uses a map per-compilation unit, rather than one per Typer. One small change required: we now need to clear this map in the the interactive compiler which reuses compilation units, rather than in the call to `Typer#reset`. --- src/interactive/scala/tools/nsc/interactive/Global.scala | 1 + 1 file changed, 1 insertion(+) (limited to 'src/interactive') diff --git a/src/interactive/scala/tools/nsc/interactive/Global.scala b/src/interactive/scala/tools/nsc/interactive/Global.scala index 0e897d6492..279b841714 100644 --- a/src/interactive/scala/tools/nsc/interactive/Global.scala +++ b/src/interactive/scala/tools/nsc/interactive/Global.scala @@ -638,6 +638,7 @@ class Global(settings: Settings, _reporter: Reporter, projectName: String = "") unit.problems.clear() unit.body = EmptyTree unit.status = NotLoaded + unit.transformed.clear() } /** Parse unit and create a name index, unless this has already been done before */ -- cgit v1.2.3