1
Fork 0

Specialize .. help message for all fields vs. the rest

This commit is contained in:
Camelid 2020-12-18 20:17:09 -08:00
parent a5e8e6ec2d
commit fe82cc38a0
9 changed files with 21 additions and 21 deletions

View file

@ -1071,14 +1071,14 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
if subpats.is_empty() || all_wildcards {
err.span_suggestion(
all_fields_span,
"use `..` to ignore all unmentioned fields",
"use `..` to ignore all fields",
String::from(".."),
Applicability::MaybeIncorrect,
);
} else {
err.span_suggestion(
after_fields_span,
"use `..` to ignore all unmentioned fields",
"use `..` to ignore the rest of the fields",
String::from(", .."),
Applicability::MaybeIncorrect,
);