shafik added a comment. In D142867#4108079 <https://reviews.llvm.org/D142867#4108079>, @eaeltsin wrote:
> The warning now fires even if overflow is prevented with `if constexpr`: > > if constexpr (width <= 64) { > if constexpr (width == 64) { > return 1; > } > return -static_cast<int64_t>(uint64_t{1} << (width - 1)); > } > > https://godbolt.org/z/M3xdcKd3M I believe this is due to issue: https://github.com/llvm/llvm-project/issues/59448 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D142867/new/ https://reviews.llvm.org/D142867 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits