All Packages Class Hierarchy This Package Previous Next Index
Class espresso.syntaxtree.AllocationExpNode
java.lang.Object
|
+----espresso.syntaxtree.SyntaxTreeNode
|
+----espresso.syntaxtree.ExpressionNode
|
+----espresso.syntaxtree.AllocationExpNode
- public class AllocationExpNode
- extends ExpressionNode
-
args_d
- An ExpressionNode vector for each dimension or for each
actual parameter of the class constructor.
-
array_d
- This flag determines if the parameters in the args_d vector
correspond to an array allocation or a constructor call.
-
className_d
- Here we keep the type name to which the invoked constructor belongs.
-
dims_d
- The number of non-empty dimensions being specified.
-
etype_d
- Type of elements allocated.
-
mnode_d
- A pointer to the constructor's declaration node.
-
AllocationExpNode(Type, Vector, boolean)
-
-
castArguments(Vector)
-
-
translate(ClassGen, MethodGen)
-
-
typeCheck(SymbolTable)
-
-
typeCheckArgs(SymbolTable)
-
etype_d
public Type etype_d
- Type of elements allocated. The final type is determined by
typeCheck() and set in the corresponding base class field.
args_d
public Vector args_d
- An ExpressionNode vector for each dimension or for each
actual parameter of the class constructor. Empty expressions
in array allocations like a[4][][] are filled with refs to
the NullLiteral.
dims_d
public int dims_d
- The number of non-empty dimensions being specified. This is
calculated by the typeCheck() method.
array_d
public boolean array_d
- This flag determines if the parameters in the args_d vector
correspond to an array allocation or a constructor call.
mnode_d
public MethodDeclarationNode mnode_d
- A pointer to the constructor's declaration node.
className_d
public Symbol className_d
- Here we keep the type name to which the invoked constructor belongs.
AllocationExpNode
public AllocationExpNode(Type type,
Vector args,
boolean array)
castArguments
private void castArguments(Vector argsType)
typeCheckArgs
private Vector typeCheckArgs(SymbolTable stable) throws TypeCheckError
typeCheck
public Type typeCheck(SymbolTable stable) throws TypeCheckError
- Overrides:
- typeCheck in class ExpressionNode
translate
public void translate(ClassGen classGen,
MethodGen methodGen)
- Overrides:
- translate in class ExpressionNode
All Packages Class Hierarchy This Package Previous Next Index