Re: [PATCH] c++: hard error w/ ptr+CST and incomplete type [PR103700]

2021-12-22 Thread Jason Merrill via Gcc-patches
On 12/22/21 12:39, Patrick Palka wrote: In pointer_int_sum when called from a SFINAE context, we need to avoid calling size_in_bytes_loc on an incomplete pointed-to type since this latter function isn't SFINAE-friendly and always emits an error in this case. Bootstrapped and regtested on

[PATCH] c++: hard error w/ ptr+CST and incomplete type [PR103700]

2021-12-22 Thread Patrick Palka via Gcc-patches
In pointer_int_sum when called from a SFINAE context, we need to avoid calling size_in_bytes_loc on an incomplete pointed-to type since this latter function isn't SFINAE-friendly and always emits an error in this case. Bootstrapped and regtested on x86_64-pc-linux-gnu, does this look OK for trunk