Re: [PATCH] c++: constexpr folding in unevaluated context [PR105931]

2022-06-23 Thread Jason Merrill via Gcc-patches
On 6/23/22 11:06, Patrick Palka wrote: Changing the type of N from int to unsigned in decltype82.C from r12-8472-g47ea22015c90df reveals another spot where we perform constexpr evaluation in an unevaluated context for sake of diagnostics, this time from the call to shorten_compare in

[PATCH] c++: constexpr folding in unevaluated context [PR105931]

2022-06-23 Thread Patrick Palka via Gcc-patches
Changing the type of N from int to unsigned in decltype82.C from r12-8472-g47ea22015c90df reveals another spot where we perform constexpr evaluation in an unevaluated context for sake of diagnostics, this time from the call to shorten_compare in cp_build_binary_op, which calls fold_for_warn. We