On 2/12/19 6:04 PM, will wray wrote:
A proposed patch for Bug 88572 is attached to the bug report along
with a short description and Change Log (a link there gives a pretty
diff of the patch):

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88572#c15

I'd appreciate any review of this patch, as well as testing on more
platforms. The patch with updated tests passes for me on x86_64.

There's also test code in bug comment #1 that demonstrates SFINAE
based on the nesting of braces. It could also be added to the
testsuite - I'm not sure how to do that or if it is needed.

+             if (cxx_dialect < cxx11 || first_initializer_p)

I would expect this to miss the error in

struct A { int i; } a = {{{42}}};

I see that we end up complaining about this in convert_like_real because implicit_conversion catches the problem here, but I think we ought to catch it in reshape_init_r as well. So, also complain if the element of the CONSTRUCTOR is also BRACE_ENCLOSED_INITIALIZER_P.

Jason

Reply via email to