about summary refs log tree commit diff
path: root/tests/ui/structs/struct-field-init-syntax.stderr
diff options
context:
space:
mode:
authorEsteban Küber <esteban@kuber.com.ar>2024-07-06 03:07:46 +0000
committerEsteban Küber <esteban@kuber.com.ar>2024-07-12 03:02:57 +0000
commit692bc344d55cf9d86c60b06c92a70684d013c89f (patch)
tree4ab084f04f99c13c3a5e84aeb405867bc3319f96 /tests/ui/structs/struct-field-init-syntax.stderr
parent5e311f933d844b6922256a0c0aa49b86159534f5 (diff)
downloadrust-692bc344d55cf9d86c60b06c92a70684d013c89f.tar.gz
rust-692bc344d55cf9d86c60b06c92a70684d013c89f.zip
Make parse error suggestions verbose and fix spans
Go over all structured parser suggestions and make them verbose style.

When suggesting to add or remove delimiters, turn them into multiple suggestion parts.
Diffstat (limited to 'tests/ui/structs/struct-field-init-syntax.stderr')
-rw-r--r--tests/ui/structs/struct-field-init-syntax.stderr14
1 files changed, 12 insertions, 2 deletions
diff --git a/tests/ui/structs/struct-field-init-syntax.stderr b/tests/ui/structs/struct-field-init-syntax.stderr
index 0b72c5cf734..66098d5f610 100644
--- a/tests/ui/structs/struct-field-init-syntax.stderr
+++ b/tests/ui/structs/struct-field-init-syntax.stderr
@@ -2,17 +2,27 @@ error: cannot use a comma after the base struct
   --> $DIR/struct-field-init-syntax.rs:11:9
    |
 LL |         ..Foo::default(),
-   |         ^^^^^^^^^^^^^^^^- help: remove this comma
+   |         ^^^^^^^^^^^^^^^^
    |
    = note: the base struct must always be the last field
+help: remove this comma
+   |
+LL -         ..Foo::default(),
+LL +         ..Foo::default()
+   |
 
 error: cannot use a comma after the base struct
   --> $DIR/struct-field-init-syntax.rs:16:9
    |
 LL |         ..Foo::default(),
-   |         ^^^^^^^^^^^^^^^^- help: remove this comma
+   |         ^^^^^^^^^^^^^^^^
    |
    = note: the base struct must always be the last field
+help: remove this comma
+   |
+LL -         ..Foo::default(),
+LL +         ..Foo::default()
+   |
 
 error: aborting due to 2 previous errors