about summary refs log tree commit diff
path: root/src/test/ui/destructuring-assignment/struct_destructure_fail.stderr
AgeCommit message (Collapse)AuthorLines
2023-01-11Move /src/test to /testsAlbert Larsan-45/+0
2021-12-14Stabilize `destructuring_assignment`Jacob Pratt-5/+5
2021-08-11Modify structured suggestion outputEsteban Küber-2/+2
* On suggestions that include deletions, use a diff inspired output format * When suggesting addition, use `+` as underline * Color highlight modified span
2021-01-26Tweak suggestion for missing field in patternsEsteban Küber-4/+4
Account for parser recovered struct and tuple patterns to avoid invalid suggestion. Follow up to #81103.
2021-01-16don't suggest erroneous trailing comma after `..`Zack M. Davis-2/+2
In #76612, suggestions were added for missing fields in patterns. However, the suggestions are being inserted just at the end of the last field in the pattern—before any trailing comma after the last field. This resulted in the "if you don't care about missing fields" suggestion to recommend code with a trailing comma after the field ellipsis (`..,`), which is actually not legal ("`..` must be at the end and cannot have a trailing comma")! Incidentally, the doc-comment on `error_unmentioned_fields` was using `you_cant_use_this_field` as an example field name (presumably copy-paste inherited from the description of Issue #76077), but the present author found this confusing, because unmentioned fields aren't necessarily unusable. The suggested code in the diff this commit introduces to `destructuring-assignment/struct_destructure_fail.stderr` doesn't work, but it didn't work beforehand, either (because of the "found reserved identifier `_`" thing), so you can't really call it a regression; it could be fixed in a separate PR. Resolves #78511.
2020-11-14Add underscore expressions for destructuring assignmentsFabian Zaiser-4/+28
Co-authored-by: varkor <github@varkor.com>
2020-11-11Implement destructuring assignment for structs and slicesFabian Zaiser-0/+21
Co-authored-by: varkor <github@varkor.com>