summaryrefslogtreecommitdiff
path: root/src/compiler/scala/tools/nsc/symtab/SymbolTable.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/compiler/scala/tools/nsc/symtab/SymbolTable.scala')
-rw-r--r--src/compiler/scala/tools/nsc/symtab/SymbolTable.scala50
1 files changed, 50 insertions, 0 deletions
diff --git a/src/compiler/scala/tools/nsc/symtab/SymbolTable.scala b/src/compiler/scala/tools/nsc/symtab/SymbolTable.scala
new file mode 100644
index 0000000000..eb29dad289
--- /dev/null
+++ b/src/compiler/scala/tools/nsc/symtab/SymbolTable.scala
@@ -0,0 +1,50 @@
+/* NSC -- new scala compiler
+ * Copyright 2005 LAMP/EPFL
+ * @author Martin Odersky
+ */
+// $Id$
+package scala.tools.nsc.symtab;
+
+import util._;
+
+abstract class SymbolTable extends Names
+ with Symbols
+ with Types
+ with Scopes
+ with Definitions
+ with Constants
+ with InfoTransformers
+ with StdNames {
+ def settings: Settings;
+ def rootLoader: LazyType;
+ def log(msg: Object): unit;
+
+ private var ph: Phase = NoPhase;
+ def phase: Phase = ph;
+ def phase_=(p: Phase): unit = {
+ //System.out.println("setting phase to " + p);
+ assert(p != null && p != NoPhase);
+ ph = p
+ }
+
+ final val NoRun = null;
+
+ /** The current compiler run. */
+ def currentRun: CompilerRun;
+
+ def atPhase[T](ph: Phase)(op: => T): T = {
+ val current = phase;
+ phase = ph;
+ val result = op;
+ phase = current;
+ result
+ }
+
+ var infoTransformers = new InfoTransformer {
+ val pid = NoPhase.id;
+ val changesBaseClasses = true;
+ def transform(sym: Symbol, tpe: Type): Type = tpe;
+ }
+
+ val phaseWithId: Array[Phase];
+}