https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94571
Bug ID: 94571 Summary: Error: Expected comma or semicolon, comma found Product: gcc Version: 10.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: bisqwit at iki dot fi Target Milestone: --- void foo() { int test1[2], test2[2]; auto [a,b] = test1, [c,d] = test2; } The error message given for this (invalid) C++17 code is a bit confusing. tmp.cc: In function ‘void foo()’: tmp.cc:4:23: error: expected ‘,’ or ‘;’ before ‘,’ token 4 | auto [a,b] = test1, [c,d] = test2; You expected comma, found comma. So what is the problem? The proper error message would be to only expect a semicolon.