https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94571

--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
(In reply to Marek Polacek from comment #4)
> I think that won't handle
> 
>   auto x(1), [e,f] = test2;
> 
> where we should also say what clang says (or at least give inform()).

That gives
error: expected unqualified-id before ‘[’ token
right now.  It would be quite a different spot that would need to handle that,
and the question is if we should do it whenever seeing just [ or if we should
in that case e.g. try to parse tentatively the structured binding or at least
part of it and only give that diagnostics if it looks like an otherwise valid
structured binding.

Reply via email to