https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87857
--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> --- The reason you get an error is that the expression isn't constant, because it needs to emit the runtime diagnostics. Just fix the bug and get away with that? 1U<<31 will do.