|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.millscript.millscript.expr.Expr<AssignAction>
org.millscript.millscript.expr.AssignExpr
public final class AssignExpr
This class implements an assign expression. This expression will never return any results.
AssignSyntax,
ApplyUpdaterExpr,
AssignAlienAction,
AssignGlobalAction,
AssignLocalAction| Constructor Summary | |
|---|---|
AssignExpr(NameExpr l,
Expr<?> r)
Creates a new assign expression for the specified name and value expressions. |
|
| Method Summary | |
|---|---|
AssignAction |
compileIt()
Compiles this expression into an action. |
static Expr |
make(Expr l,
Expr r)
Returns an expression to assign the result of the right hand side expression to the result of the left hand side expression. |
void |
resolve(CompilerState state)
Resolves any NameExpr in the tree so that they refer to the
correct ident. |
| Methods inherited from class org.millscript.millscript.expr.Expr |
|---|
arity, compile, isIntegerExpr, resolveList, setLineNumber, setOrigin, show, show |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AssignExpr(NameExpr l,
Expr<?> r)
l - the name expression to assign tor - the value expression to assign from, which should return a
single result| Method Detail |
|---|
public static Expr make(Expr l,
Expr r)
l - the expression to assign to, this should be an
ApplyExpr or NameExprr - the expression to assign from
ApplyUpdaterExpr if the left hand side is an
ApplyExpr, otherwise an AssignExprpublic AssignAction compileIt()
Expr
compileIt in class Expr<AssignAction>Action for this expressionExpr.compileIt()public void resolve(CompilerState state)
ExprNameExpr in the tree so that they refer to the
correct ident. e.g. This method is responsible for ensuring that
references to a function argument in the body of a function actually
refer to the correct value.
resolve in class Expr<AssignAction>state - the compiler state we are resolving inExpr.resolve(org.millscript.millscript.vm.CompilerState)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||