abstract class JBinaryExpression extends JExpression
| Modifier and Type | Field and Description |
|---|---|
protected JExpression |
lhs
The lhs operand.
|
protected String |
operator
The binary operator.
|
protected JExpression |
rhs
The rhs operand.
|
isStatementExpression, typecompilationUnit, line| Modifier | Constructor and Description |
|---|---|
protected |
JBinaryExpression(int line,
String operator,
JExpression lhs,
JExpression rhs)
Construct an AST node for a binary expression given its line number, the
binary operator, and lhs and rhs operands.
|
| Modifier and Type | Method and Description |
|---|---|
void |
writeToStdOut(PrettyPrinter p)
Write the information pertaining to this AST to STDOUT.
|
analyze, codegen, isStatementExpression, typecodegen, line, partialCodegenprotected String operator
protected JExpression lhs
protected JExpression rhs
protected JBinaryExpression(int line,
String operator,
JExpression lhs,
JExpression rhs)
line - line in which the binary expression occurs in the source file.operator - the binary operator.lhs - the lhs operand.rhs - the rhs operand.public void writeToStdOut(PrettyPrinter p)
JASTwriteToStdOut in class JASTp - for pretty printing with indentation.