What does “|=” mean? (pipe equal operator)
|= reads the same way as +=. is the same as where | is the bit-wise OR operator. All operators are referenced here. A bit-wise operator is used because, as is frequent, those constants enable an int to carry flags. If you look at those constants, you’ll see that they’re in powers of two : So you can use bit-wise OR to … Read more