Formatting
This commit is contained in:
parent
3b9c44434e
commit
2a72de9f81
1 changed files with 4 additions and 2 deletions
|
@ -15,9 +15,11 @@ class Interpreter implements Expr.Visitor<Object>, Stmt.Visitor<Void> {
|
|||
Object left = evaluate(expr.left);
|
||||
|
||||
if (expr.operator.type == TokenType.OR) {
|
||||
if (isTruthy(left)) return left;
|
||||
if (isTruthy(left))
|
||||
return left;
|
||||
} else {
|
||||
if (!isTruthy(left)) return left;
|
||||
if (!isTruthy(left))
|
||||
return left;
|
||||
}
|
||||
|
||||
return evaluate(expr.right);
|
||||
|
|
Loading…
Reference in a new issue