summaryrefslogtreecommitdiff
path: root/src/compiler/scala/tools/nsc/Global.scala
diff options
context:
space:
mode:
authorSean McDirmid <sean.mcdirmid@gmail.com>2006-01-18 18:49:01 +0000
committerSean McDirmid <sean.mcdirmid@gmail.com>2006-01-18 18:49:01 +0000
commitac90ad939c03366948f435bb603b56c7ab6bc2ce (patch)
treef41f3ffaf87cce3bf8ca77a97936998f6b128327 /src/compiler/scala/tools/nsc/Global.scala
parent65fa4b28064614f446f34b3278361a270bcc93f3 (diff)
downloadscala-ac90ad939c03366948f435bb603b56c7ab6bc2ce.tar.gz
scala-ac90ad939c03366948f435bb603b56c7ab6bc2ce.tar.bz2
scala-ac90ad939c03366948f435bb603b56c7ab6bc2ce.zip
Diffstat (limited to 'src/compiler/scala/tools/nsc/Global.scala')
-rw-r--r--src/compiler/scala/tools/nsc/Global.scala25
1 files changed, 14 insertions, 11 deletions
diff --git a/src/compiler/scala/tools/nsc/Global.scala b/src/compiler/scala/tools/nsc/Global.scala
index 30a1217945..cdf0b82e29 100644
--- a/src/compiler/scala/tools/nsc/Global.scala
+++ b/src/compiler/scala/tools/nsc/Global.scala
@@ -420,18 +420,21 @@ class Global(val settings: Settings, val reporter: Reporter) extends SymbolTable
}
def compileLate(file: AbstractFile): unit =
- if (fileset == null)
- throw new FatalError("No class file for " + file + " was found\n(This file cannot be loaded as a source file)");
+ if (fileset == null) {
+ val msg = "No class file for " + file + " was found\n(This file cannot be loaded as a source file)";
+ System.err.println(msg);
+ throw new FatalError(msg);
+ }
else if (!(fileset contains file)) {
- val unit = new CompilationUnit(getSourceFile(file));
- addUnit(unit);
- var localPhase = firstPhase.asInstanceOf[GlobalPhase];
- while ((localPhase.id < globalPhase.id || localPhase.id <= namerPhase.id) &&
- reporter.errors == 0) {
- atPhase(localPhase)(localPhase.applyPhase(unit));
- localPhase = localPhase.next.asInstanceOf[GlobalPhase];
- }
- refreshProgress;
+ val unit = new CompilationUnit(getSourceFile(file));
+ addUnit(unit);
+ var localPhase = firstPhase.asInstanceOf[GlobalPhase];
+ while ((localPhase.id < globalPhase.id || localPhase.id <= namerPhase.id) &&
+ reporter.errors == 0) {
+ atPhase(localPhase)(localPhase.applyPhase(unit));
+ localPhase = localPhase.next.asInstanceOf[GlobalPhase];
+ }
+ refreshProgress;
}
def compileFiles(files: List[AbstractFile]): unit =