Avoid undefined shift behaviour if bit depth == 32 (#895)