|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectharpoon.Tools.PatMat.Spec.Exp
harpoon.Tools.PatMat.Spec.ExpBinop
public static class Spec.ExpBinop
Extension of Spec.Exp
that represents a Binary
Operation in the code. An implicit restriction on our binary
operations is that both operands must have equivalent domains
(there is only one Spec.TypeSet
for a given
Spec.ExpBinop
).
BINOP
Field Summary | |
---|---|
Spec.Exp |
left
Expression on the left side of this . |
Spec.Leaf |
opcode
Opcode for this . |
Spec.Exp |
right
Expression on the right side of this . |
Spec.TypeSet |
types
Types of values that this operates on. |
Constructor Summary | |
---|---|
Spec.ExpBinop(Spec.TypeSet types,
Spec.Leaf opcode,
Spec.Exp left,
Spec.Exp right)
Constructs a Spec.ExpBinop that operates on
expressions of types . |
Method Summary | |
---|---|
void |
accept(Spec.ExpVisitor v)
Applies v 's visit method to
this . |
Spec.Exp |
build(Spec.ExpList kids)
Creates a new Spec.Exp similar to this one,
using the provided Spec.ExpList of children. |
Spec.ExpList |
kids()
Creates an Spec.ExpList of children of this
Spec.Exp . |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public final Spec.TypeSet types
this
operates on.
public final Spec.Leaf opcode
this
.
Bop
public final Spec.Exp left
this
.
public final Spec.Exp right
this
.
Constructor Detail |
---|
public Spec.ExpBinop(Spec.TypeSet types, Spec.Leaf opcode, Spec.Exp left, Spec.Exp right)
Spec.ExpBinop
that operates on
expressions of types
.
types
- Types that left
and
right
may be.opcode
- The binary operation that is being performed
on left
and right
.left
- The left operand.right
- The right operand.Method Detail |
---|
public void accept(Spec.ExpVisitor v)
Spec.Exp
v
's visit
method to
this
. This is effectively a gludge to
emulate multiple dispatch. Must be reimplemented
by all subclasses of Spec.Exp
.
v.visit(this)
.
accept
in class Spec.Exp
public Spec.Exp build(Spec.ExpList kids)
Spec.Exp
Spec.Exp
similar to this one,
using the provided Spec.ExpList
of children.
build
in class Spec.Exp
public Spec.ExpList kids()
Spec.Exp
Spec.ExpList
of children of this
Spec.Exp
.
kids
in class Spec.Exp
public String toString()
toString
in class Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |