aboutsummaryrefslogtreecommitdiff
path: root/src/dotty/tools/dotc/Compiler.scala
diff options
context:
space:
mode:
authorMartin Odersky <odersky@gmail.com>2014-02-24 13:21:24 +0100
committerMartin Odersky <odersky@gmail.com>2014-02-24 18:56:48 +0100
commitcdeafeafd252b20a0df5440e0420211af95e0cdc (patch)
treea2112ebe760b54d923f20305f2c29429d7f7cf6b /src/dotty/tools/dotc/Compiler.scala
parent91e74ee45c8cedac279ec66f8277c94d05f2f2e3 (diff)
downloaddotty-cdeafeafd252b20a0df5440e0420211af95e0cdc.tar.gz
dotty-cdeafeafd252b20a0df5440e0420211af95e0cdc.tar.bz2
dotty-cdeafeafd252b20a0df5440e0420211af95e0cdc.zip
Resetting uniques and hashset reorg.
Uniques are now cleared after each run. Also, HashSets get a more standard API, without a label, but with configurable load factor.
Diffstat (limited to 'src/dotty/tools/dotc/Compiler.scala')
-rw-r--r--src/dotty/tools/dotc/Compiler.scala6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/dotty/tools/dotc/Compiler.scala b/src/dotty/tools/dotc/Compiler.scala
index f6723ddf4..38e3c8fd8 100644
--- a/src/dotty/tools/dotc/Compiler.scala
+++ b/src/dotty/tools/dotc/Compiler.scala
@@ -30,6 +30,8 @@ class Compiler {
(start.withRunInfo(new RunInfo(start)) /: defn.RootImports)(addImport)
}
- def newRun(implicit ctx: Context): Run =
- new Run(this)(rootContext)
+ def newRun(implicit ctx: Context): Run = {
+ try new Run(this)(rootContext)
+ finally ctx.base.reset()
+ }
} \ No newline at end of file