Do &= and |= short-circuit in Java?
No, |= and &= do not shortcircuit, because they are the compound assignment version of & and |, which do not shortcircuit. JLS 15.26.2 Compound Assignment Operators A compound assignment expression of the form E1 op= E2 is equivalent to E1 = (T)((E1) op (E2)), where T is the type of E1, except that E1 …