SourceLocator.Simple
Modifier and Type | Field and Description |
---|---|
static int |
ALLOCATE_ON_STACK_LAST |
static int |
DONT_DEREFERENCE |
static int |
PROCEDURE_NAME |
static int |
TYPE_NAME
Flag indicates a reference to a type name.
|
NEXT_AVAIL_FLAG, PREFER_BINDING2
applyMethodExpression, flags, noExpressions, type, VALIDATED
applyMethodType, applyToConsumerDefault, applyToConsumerMethod, applyToObjectDefault, applyToObjectMethod, compilerKey, compilerXKey, inlineIfConstantSymbol, validateApplyKey, validateXApplyKey
nameKey
Constructor and Description |
---|
ReferenceExp(Declaration binding) |
ReferenceExp(java.lang.Object symbol) |
ReferenceExp(java.lang.Object symbol,
Declaration binding) |
ReferenceExp(ReferenceExp old) |
Modifier and Type | Method and Description |
---|---|
void |
apply(CallContext ctx)
Evaluate the expression.
|
protected Type |
calculateType() |
void |
compile(Compilation comp,
Target target) |
protected Expression |
deepCopy(IdentityHashTable mapper) |
boolean |
getDontDereference() |
boolean |
isProcedureName()
True if this identifier appears in "function call position".
|
boolean |
isSingleValue() |
boolean |
isUnknown() |
protected boolean |
mustCompile() |
void |
print(gnu.kawa.io.OutPort ps) |
void |
setDontDereference(boolean setting) |
void |
setProcedureName(boolean setting)
Note if this identifier appears in "function call position".
|
boolean |
side_effects()
True if evaluating may have side-effects.
|
java.lang.String |
toString() |
Expression |
validateApply(ApplyExp exp,
InlineCalls visitor,
Type required,
Declaration decl)
Apply inlining transformations on a given ApplyExp.
|
java.lang.Object |
valueIfConstant()
Return value if it is constant, or null if non-constant or unknown.
|
protected <R,D> R |
visit(ExpVisitor<R,D> visitor,
D d) |
contextDecl, getBinding, getName, getSimpleName, getSymbol, setBinding, setContextDecl, string_name
applyMethodExpression, checkLiteralKeyword, compile, compile, compileWithPosition, compileWithPosition, deepCopy, deepCopy, deepCopy, eval, eval, getColumnNumber, getEndColumn, getEndLine, getFileName, getFlag, getFlags, getLineNumber, getPublicId, getStartColumn, getStartLine, getSystemId, getType, getTypeRaw, isStableSourceLocation, makeWhile, maybeSetLine, neverReturns, numArgs, print, printLineColumn, setFile, setFlag, setFlag, setLine, setLine, setLine, setLine, setLine, setLocation, setType, visitChildren
apply0, apply1, apply2, apply3, apply4, applyL, applyN, applyToConsumerDefault, applyToObjectDefault, checkArgCount, checkBadCode, getApplyMethod, getApplyToConsumerMethod, getApplyToObjectMethod, getReturnType, getSetter, getSourceLocation, isSideEffectFree, lookupApplyHandle, maxArgs, maxArgs, minArgs, minArgs, set0, set1, setN, setSetter, setSourceLocation
getProperty, removeProperty, setName, setProperty, setProperty, setSymbol
public static final int DONT_DEREFERENCE
public static final int PROCEDURE_NAME
public static final int TYPE_NAME
public static final int ALLOCATE_ON_STACK_LAST
public ReferenceExp(java.lang.Object symbol)
public ReferenceExp(java.lang.Object symbol, Declaration binding)
public ReferenceExp(Declaration binding)
public ReferenceExp(ReferenceExp old)
public final boolean getDontDereference()
public final void setDontDereference(boolean setting)
public final boolean isUnknown()
public final boolean isProcedureName()
public final void setProcedureName(boolean setting)
protected boolean mustCompile()
mustCompile
in class Expression
public final java.lang.Object valueIfConstant()
Expression
valueIfConstant
in class Expression
public void apply(CallContext ctx) throws java.lang.Throwable
Expression
apply
in class Expression
java.lang.Throwable
public void compile(Compilation comp, Target target)
compile
in class Expression
protected Expression deepCopy(IdentityHashTable mapper)
deepCopy
in class Expression
protected <R,D> R visit(ExpVisitor<R,D> visitor, D d)
visit
in class Expression
public Expression validateApply(ApplyExp exp, InlineCalls visitor, Type required, Declaration decl)
Expression
validateApply
in class Expression
exp
- an application whose function expression can be simplified
to this expression.visitor
- the context for the current inlining passdecl
- if non-null, a Declaration bound to this expression.public void print(gnu.kawa.io.OutPort ps)
print
in class Expression
protected Type calculateType()
calculateType
in class Expression
public boolean isSingleValue()
isSingleValue
in class Expression
public boolean side_effects()
Expression
side_effects
in class Expression
public java.lang.String toString()
toString
in class Expression