Using the guard to implement part of the rule https://eel.is/c++draft/dcl.pre#6.
void foo() { // can be parsed as // - structured-binding declaration (a false parse) // - assignment expression array[index] = value; }
Paths
| Differential D132260
[pseudo] Eliminate a false parse of structured binding declaration. ClosedPublic Authored by hokein on Aug 19 2022, 1:01 PM.
Details Summary Using the guard to implement part of the rule https://eel.is/c++draft/dcl.pre#6. void foo() { // can be parsed as // - structured-binding declaration (a false parse) // - assignment expression array[index] = value; }
Diff Detail
Event Timelinesammccall added inline comments.
This revision is now accepted and ready to land.Aug 22 2022, 7:38 AM This revision was landed with ongoing or failed builds.Aug 23 2022, 6:26 AM Closed by commit rGf7dc91ad5609: [pseudo] Eliminate a false parse of structured binding declaration. (authored by hokein). · Explain Why This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 454817 clang-tools-extra/pseudo/lib/cxx/CXX.cpp
clang-tools-extra/pseudo/lib/cxx/cxx.bnf
clang-tools-extra/pseudo/test/cxx/structured-binding.cpp
|
nit: specifiesStructuredBinding?
(because the structured binding itself is something bigger)