summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiles Sabin <miles@milessabin.com>2009-07-30 14:14:25 +0000
committerMiles Sabin <miles@milessabin.com>2009-07-30 14:14:25 +0000
commit6148dff45ac80067b86b8e34102dfc315334821e (patch)
treefab22fe8afb138b26264b85684f229c4ff1885ec
parentc5af4c0388eab5b4f9aff647e09fa89e87bea0b6 (diff)
downloadscala-6148dff45ac80067b86b8e34102dfc315334821e.tar.gz
scala-6148dff45ac80067b86b8e34102dfc315334821e.tar.bz2
scala-6148dff45ac80067b86b8e34102dfc315334821e.zip
When both updating and removing, don't build tw...
When both updating and removing, don't build twice.
-rw-r--r--src/compiler/scala/tools/nsc/interactive/RefinedBuildManager.scala8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/compiler/scala/tools/nsc/interactive/RefinedBuildManager.scala b/src/compiler/scala/tools/nsc/interactive/RefinedBuildManager.scala
index 8368990cde..2e300af012 100644
--- a/src/compiler/scala/tools/nsc/interactive/RefinedBuildManager.scala
+++ b/src/compiler/scala/tools/nsc/interactive/RefinedBuildManager.scala
@@ -66,11 +66,13 @@ class RefinedBuildManager(val settings: Settings) extends Changes with BuildMana
}
def update(added: Set[AbstractFile], removed: Set[AbstractFile]) {
- removeFiles(removed)
- update(added)
+ sources --= removed
+ val changes = new mutable.HashMap[Symbol, List[Change]]
+ for (f <- removed; sym <- definitions(f))
+ changes += sym -> List(Removed(Class(sym.fullNameString)))
+ update(added ++ invalidated(removed, changes))
}
-
/** The given files have been modified by the user. Recompile
* them and all files that depend on them. Only files that
* have been previously added as source files are recompiled.