diff options
author | Martin Odersky <odersky@gmail.com> | 2005-06-02 18:32:58 +0000 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2005-06-02 18:32:58 +0000 |
commit | 2b80c3e689522c4c8adcee49d85836005b6ea187 (patch) | |
tree | 95df01204f6727d23312b0d99f804c099f1a3b72 /sources/scala/tools/nsc/SubComponent.scala | |
parent | 364559e23368475e9bfad26fd28f229842b3e97b (diff) | |
download | scala-2b80c3e689522c4c8adcee49d85836005b6ea187.tar.gz scala-2b80c3e689522c4c8adcee49d85836005b6ea187.tar.bz2 scala-2b80c3e689522c4c8adcee49d85836005b6ea187.zip |
*** empty log message ***
Diffstat (limited to 'sources/scala/tools/nsc/SubComponent.scala')
-rw-r--r-- | sources/scala/tools/nsc/SubComponent.scala | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/sources/scala/tools/nsc/SubComponent.scala b/sources/scala/tools/nsc/SubComponent.scala new file mode 100644 index 0000000000..dbec8b8f93 --- /dev/null +++ b/sources/scala/tools/nsc/SubComponent.scala @@ -0,0 +1,23 @@ +/* NSC -- new scala compiler + * Copyright 2005 LAMP/EPFL + * @author Martin Odersky + */ +// $Id$ +package scala.tools.nsc; + +/** An nsc sub-component. + */ +abstract class SubComponent { + + val global: Global; + + abstract class StdPhase(prev: Phase) extends Phase(prev) { + def run: unit = + for (val unit <- global.units) { + if (global.settings.debug.value) System.out.println("[running phase " + name + " on " + unit + "]");//debug + apply(unit); + } + def apply(unit: global.CompilationUnit): unit; + } +} + |