improve clunky grammar in borrowck diagnostic
This commit is contained in:
parent
86d2129a78
commit
6680bc5554
2 changed files with 3 additions and 3 deletions
|
@ -2695,7 +2695,7 @@ impl<'infcx, 'tcx> MirBorrowckCtxt<'_, 'infcx, 'tcx> {
|
||||||
}
|
}
|
||||||
|
|
||||||
err.multipart_suggestion_verbose(
|
err.multipart_suggestion_verbose(
|
||||||
"try explicitly pass `&Self` into the Closure as an argument",
|
"try explicitly passing `&Self` into the closure as an argument",
|
||||||
sugg,
|
sugg,
|
||||||
Applicability::MachineApplicable,
|
Applicability::MachineApplicable,
|
||||||
);
|
);
|
||||||
|
|
|
@ -11,7 +11,7 @@ LL | self.qux();
|
||||||
LL | x(1);
|
LL | x(1);
|
||||||
| - immutable borrow later used here
|
| - immutable borrow later used here
|
||||||
|
|
|
|
||||||
help: try explicitly pass `&Self` into the Closure as an argument
|
help: try explicitly passing `&Self` into the closure as an argument
|
||||||
|
|
|
|
||||||
LL ~ let x = |this: &Self, v: i32| {
|
LL ~ let x = |this: &Self, v: i32| {
|
||||||
LL ~ this.bar();
|
LL ~ this.bar();
|
||||||
|
@ -35,7 +35,7 @@ LL | self.qux();
|
||||||
LL | y();
|
LL | y();
|
||||||
| - immutable borrow later used here
|
| - immutable borrow later used here
|
||||||
|
|
|
|
||||||
help: try explicitly pass `&Self` into the Closure as an argument
|
help: try explicitly passing `&Self` into the closure as an argument
|
||||||
|
|
|
|
||||||
LL ~ let y = |this: &Self| {
|
LL ~ let y = |this: &Self| {
|
||||||
LL ~ this.bar();
|
LL ~ this.bar();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue