Abstract class for syntactic forms that evaluate to a value.
Scheme S-expressions get re-written to these before evaluation.
apply0
public final Object apply0()
throws Throwable
- apply0 in interface Procedure0
compileNotePosition
public final void compileNotePosition(Compilation comp,
Target target,
Expression position)
Compile, but take note of line number.
compileWithPosition
public final void compileWithPosition(Compilation comp,
Target target)
Same as compile, but emit line number beforehard.
compileWithPosition
public final void compileWithPosition(Compilation comp,
Target target,
Expression position)
Same as 2-argument compileWithPosition,
but use some other Expression's line number.
eval
public final Object eval(CallContext ctx)
throws Throwable
eval
public Object eval(Environment env)
throws Throwable
getColumn
public final int getColumn()
getFile
public final String getFile()
getFlag
public boolean getFlag(int flag)
getFlags
public int getFlags()
getLine
public final int getLine()
Get the line number of (the start of) this Expression.
The "first" line is line 1.
getType
public Type getType()
Return the Type used to represent the values of this Expression.
makeWhile
public static Expression makeWhile(Object cond,
Object body,
Compilation parser)
Helper method to create a `while' statement.
print
public abstract void print(OutPort ps)
print
public final void print(java.io.PrintWriter ps)
printLineColumn
public void printLineColumn(OutPort out)
Print line and column number if specified.
This is a helper routineintended for use by print(OutPort).
setFile
public final void setFile(String filename)
setFlag
public void setFlag(boolean setting,
int flag)
setFlag
public void setFlag(int flag)
setLine
public void setLine(Compilation comp)
Set line number from current position in Compilation
.
setLine
public final void setLine(int lineno)
setLine
public final void setLine(int lineno,
int colno)
walkChildren
protected void walkChildren(ExpWalker walker)