if (boe.leftExpression instanceof NumberLiteral
&& boe.rightExpression instanceof NumberLiteral) {
double left = ((NumberLiteral) boe.leftExpression).value;
double right = ((NumberLiteral) boe.rightExpression).value;
Token op = boe.operator;
if (op == Token.OPERATOR_PLUS) {
return new NumberLiteral(left + right);
} else if (op == Token.OPERATOR_MINUS) {
return new NumberLiteral(left - right);