All Packages Class Hierarchy This Package Previous Next Index
Class espresso.Espresso
java.lang.Object
|
+----espresso.Espresso
- public class Espresso
- extends Object
-
currentClass_d
-
Keep the name of the type that is being compiled.
-
errors_d
- A string vector that collects errors from the various compilation
phases: parsing, type checking, etc.
-
fileName_d
-
Keep the name of the source file that is being compiled.
-
importMgr_d
- A reference to the symbol table.
-
instance_d
- A static reference to the main object.
-
parser_d
- A reference to a JavaParser object.
-
root_d
-
A pointer to the AST root node.
-
symbolTable_d
- A reference to the symbol table.
-
TABLE_SIZE
- Initial size of the symbol table.
-
Espresso()
- The only constructor.
-
currentClass()
-
-
currentClass(Symbol)
-
-
currentPackage()
-
-
defineInitEnv()
- Define entries in the symbol table for all the primops.
-
errors()
-
-
execute(String[])
- Espresso's main loop.
-
fileName()
-
-
importMgr()
-
-
internalError()
- Aborts the execution of the compiler as a result of an
unrecoverable error.
-
main(String[])
- Entry point.
-
notYetImplemented()
- Aborts the execution of the compiler if something found
in the source file can't be compiled.
-
printErrors()
-
-
symbolTable()
-
TABLE_SIZE
static final int TABLE_SIZE
- Initial size of the symbol table. Other interesing
primes are 211, 307, 401, 503, 601, 701, 809, 907.
errors_d
Vector errors_d
- A string vector that collects errors from the various compilation
phases: parsing, type checking, etc.
parser_d
JavaParser parser_d
- A reference to a JavaParser object.
symbolTable_d
SymbolTable symbolTable_d
- A reference to the symbol table.
importMgr_d
JavaImportManager importMgr_d
- A reference to the symbol table.
root_d
CompilationUnitNode root_d
- A pointer to the AST root node.
currentClass_d
Symbol currentClass_d
- Keep the name of the type that is being compiled.
fileName_d
String fileName_d
- Keep the name of the source file that is being compiled.
instance_d
static Espresso instance_d
- A static reference to the main object.
Espresso
public Espresso()
- The only constructor.
defineInitEnv
private void defineInitEnv()
- Define entries in the symbol table for all the primops. This entries
will be used by the type checker. The entries in the symbol table
must be sorted from the widest type (e.g, double) to the narrowest
(e.g, int).
execute
public void execute(String args[])
- Espresso's main loop.
internalError
public static void internalError()
- Aborts the execution of the compiler as a result of an
unrecoverable error.
notYetImplemented
public static void notYetImplemented()
- Aborts the execution of the compiler if something found
in the source file can't be compiled.
printErrors
private void printErrors()
errors
public static Vector errors()
symbolTable
public static SymbolTable symbolTable()
fileName
public static String fileName()
importMgr
public static JavaImportManager importMgr()
currentPackage
public static Symbol currentPackage()
currentClass
public static void currentClass(Symbol name)
currentClass
public static Symbol currentClass()
main
public static void main(String args[])
- Entry point.
All Packages Class Hierarchy This Package Previous Next Index