Skip to content

Commit

Permalink
chore: format.
Browse files Browse the repository at this point in the history
  • Loading branch information
7086cmd authored and Boshen committed Oct 2, 2024
1 parent b11b88b commit e557a7f
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,9 @@ impl<'a> PeepholeSubstituteAlternateSyntax {
} else {
false
}
}).next().unwrap_or(false);
})
.next()
.unwrap_or(false);
// XOR: We should use `!neg` when it is not in binary expression.
let num = ctx.ast.expression_numeric_literal(
SPAN,
Expand Down Expand Up @@ -386,7 +388,7 @@ mod test {

test("x instanceof true", "x instanceof !0");
test("x + false", "x + !1");

// Order: should perform the nearest.
test("x == x instanceof false", "x == x instanceof !1");
test("x in x >> true", "x in x >> 1");
Expand Down

0 comments on commit e557a7f

Please sign in to comment.