[clang] Add flag to suppress overflow errors in C++ constant expressions. (PR #102390)

via cfe-commits cfe-commits at lists.llvm.org
Thu Aug 8 06:01:17 PDT 2024


cor3ntin wrote:

I agree with @AaronBallman that, given there hasn't been a lot of outstanding complaints following https://github.com/llvm/llvm-project/pull/70307, we don't want to allow that sort of relaxation of constexpr evaluation as it's both non conforming (and potentially problematic for people who rely on constant evaluation to enforce the soundness of their code)

If that change was in fact a lot more disruptive beyond the already patched NDK, I think we could consider a more targeted error for shifts only (rather than allowing _any_ overflow to be ignored).

https://github.com/llvm/llvm-project/pull/102390


More information about the cfe-commits mailing list