Skip to content

Commit 7635988

Browse files
committed
fix for |= and &| not being bitwise
1 parent e01e250 commit 7635988

3 files changed

Lines changed: 2 additions & 2 deletions

File tree

-1 Bytes
Binary file not shown.
-1 Bytes
Binary file not shown.

sources/net.sf.j2s.core/src/net/sf/j2s/core/astvisitors/Java2ScriptVisitor.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2050,10 +2050,10 @@ public boolean visit(Assignment node) {
20502050
left.accept(this);
20512051
switch (op) {
20522052
case "|=":
2053-
buffer.append("||");
2053+
buffer.append("|"); // surprise! | not ||
20542054
break;
20552055
case "&=":
2056-
buffer.append("&&");
2056+
buffer.append("&"); // & not &&
20572057
break;
20582058
default:
20592059
case "^=":

0 commit comments

Comments
 (0)