Rollup merge of #99789 - TaKO8Ki:use-pluralize-macro, r=compiler-errors
Refactor: use `pluralize!` Use `pluralize!` in more places
This commit is contained in:
commit
e0f88b3e9c
5 changed files with 10 additions and 12 deletions
|
@ -631,9 +631,9 @@ impl<'a, 'tcx> InferCtxtExt<'tcx> for InferCtxt<'a, 'tcx> {
|
|||
&format!(
|
||||
"expected a closure taking {} argument{}, but one taking {} argument{} was given",
|
||||
given.len(),
|
||||
if given.len() == 1 { "" } else { "s" },
|
||||
pluralize!(given.len()),
|
||||
expected.len(),
|
||||
if expected.len() == 1 { "" } else { "s" },
|
||||
pluralize!(expected.len()),
|
||||
)
|
||||
);
|
||||
} else if !self.same_type_modulo_infer(given_ty, expected_ty) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue