Correct SHIFT bug#2067
Replace undefined arithmetic
Detect overflow of arithmetic shift
Merge branch 'shift' into community