I know such topic was asked several times, but my question is about overflow on full 32 bits of int. For example:
11111111111111111111111
long test = (long)x+y; if (test > Integer.MAX_VALUE || test < Integer.MIN_VALUE) // Overflow!