and
ing with zero, or
ing by zero,
and shifting by zero. Such expressions may be the result of automated refactorings
not completely followed through to completion, and in any case are unlikely to be what the developer
intended to do.
Examples:
// Warning: operation is pointless and can be replaced with just `flags` int bits = flags & 0xFFFFFFFF; // Warning: operation is pointless and can be replaced with just `bits` int or = bits | 0x0; // Warning: operation is pointless, as always results in 0 int xor = or ^ or;