On Fri, Jun 30, 2017 at 3:35 PM, Jakub Jelinek <ja...@redhat.com> wrote: > On Fri, Jun 30, 2017 at 03:15:21PM -0400, Jason Merrill wrote: >> On Fri, Jun 30, 2017 at 1:26 PM, Jakub Jelinek <ja...@redhat.com> wrote: >> > Hi! >> > >> > As C++17 decided to rename decompositions to structured bindings, this >> > patch attempts to adjust the diagnostics by replacing >> > "decomposition declaration" with "structured binding". >> > Or shall I use "structured binding declaration" instead (or is that too >> > longer/verbose), or something different? >> >> "structured binding declaration" is better when you're talking about >> the declaration syntax. When you're talking about the feature in the >> first hunk, "structured bindings". "structured binding variable" is >> good in the one hunk where you've used that. > > What about that: > case cdk_decomp: > - name = "decomposition"; > + name = "structured binding"; > break; > hunk?
I think that's OK. > Also, aren't there too many "declar*" roots, both in the previous > "decomposition declaration cannot be declared" > and > "structured binding declaration cannot be declared" > ? I mean wouldn't be "structured bindings cannot be declared" > or "structured binding cannot be declared" better in that case? Well, the term "structured binding" refers to one of the names declared by the declaration, not the declaration as a whole, and those errors refer to the latter. We could change "cannot be declared" to something else, perhaps just drop the "declared", so e.g. "structured binding declaration cannot be %<constexpr%>"? Or "cannot use X specifier"? Jason