Re: [PATCH] c++: Fix wrong paren-init of aggregates interference [PR93790]

2020-04-08 Thread Jason Merrill via Gcc-patches
On 4/8/20 5:52 PM, Marek Polacek wrote: This PR points out that we are rejecting valid code in C++20. The problem is that we were surreptitiously transforming T& t(e) into T& t{e} which is wrong, because the type of e had a conversion function to T, while aggregate initialization of t

[PATCH] c++: Fix wrong paren-init of aggregates interference [PR93790]

2020-04-08 Thread Marek Polacek via Gcc-patches
This PR points out that we are rejecting valid code in C++20. The problem is that we were surreptitiously transforming T& t(e) into T& t{e} which is wrong, because the type of e had a conversion function to T, while aggregate initialization of t from e doesn't work. Therefore, I was viola