|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectharpoon.IR.Quads.Quad
harpoon.IR.Quads.NOP
harpoon.IR.Quads.TYPECAST
public class TYPECAST
TYPECAST
performs a typecast on a given variable.
It throws an exception if the Temp
cannot be type cast
as requested. It is similar to the bytecode checkcast
instruction.
Field Summary | |
---|---|
protected HClass |
hclass
The class to cast to. |
protected Temp |
objectref
The Temp to type cast. |
Fields inherited from class harpoon.IR.Quads.Quad |
---|
arrayFactory |
Constructor Summary | |
---|---|
TYPECAST(QuadFactory qf,
HCodeElement source,
Temp objectref,
HClass hclass)
Creates a TYPECAST representing a type cast. |
Method Summary | ||
---|---|---|
|
accept(QuadValueVisitor<T> v)
|
|
void |
accept(QuadVisitor v)
Accept a visitor. |
|
HClass |
hclass()
Return the class of this TYPECAST . |
|
int |
kind()
Return an integer enumeration of the kind of this Quad . |
|
Temp |
objectref()
Return the Temp type cast by this TYPECAST . |
|
Quad |
rename(QuadFactory qqf,
TempMap defMap,
TempMap useMap)
Create a new Quad identical to the receiver, but
with all Temp s renamed according to a mapping. |
|
String |
toString()
Returns a human-readable representation of this Quad . |
|
Temp[] |
use()
Returns the Temp s used by this quad. |
Methods inherited from class harpoon.IR.Quads.Quad |
---|
addEdge, addEdges, addHandlers, clone, clone, clone, compareTo, def, defC, edgeC, edges, getFactory, getID, getLineNumber, getSourceFile, handlers, hashCode, isPred, isSucc, map, map, map, next, next, nextEdge, nextEdge, nextLength, pred, predC, prev, prev, prevEdge, prevEdge, prevLength, remove, removeHandlers, rename, replace, succ, succC, toLongString, transferHandlers, useC |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected Temp objectref
Temp
to type cast.
protected final HClass hclass
Constructor Detail |
---|
public TYPECAST(QuadFactory qf, HCodeElement source, Temp objectref, HClass hclass)
TYPECAST
representing a type cast.
objectref
- the Temp
to type cast.hclass
- the class to cast to.Method Detail |
---|
public Temp objectref()
Temp
type cast by this TYPECAST
.
public HClass hclass()
TYPECAST
.
public Temp[] use()
Temp
s used by this quad.
use
in interface UseDefable
use
in class Quad
public int kind()
Quad
Quad
. The enumerated values are defined in
QuadKind
.
kind
in class NOP
public Quad rename(QuadFactory qqf, TempMap defMap, TempMap useMap)
Quad
Quad
identical to the receiver, but
with all Temp
s renamed according to a mapping.
The new Quad
will have no edges.
The new Quad
will come from the specified
QuadFactory
.
rename
in class NOP
public void accept(QuadVisitor v)
Quad
accept
in class NOP
public <T> T accept(QuadValueVisitor<T> v)
accept
in class NOP
public String toString()
Quad
.
toString
in class NOP
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |