mirror of https://github.com/rust-lang/rfcs.git
Update text/3668-async-closure.md
whoops forgot a mut Co-authored-by: zachs18 <8355914+zachs18@users.noreply.github.com>
This commit is contained in:
parent
662654b36a
commit
ee9b0cd5fd
|
@ -357,7 +357,7 @@ let closure = async || {
|
|||
};
|
||||
```
|
||||
|
||||
The closure captures `vec` with some `&'closure mut Vec<String>` which lives until the closure is dropped. Then every call to the closure reborrows that mutable reference `&'call Vec<String>` which lives until the future is dropped (e.g. `await`ed).
|
||||
The closure captures `vec` with some `&'closure mut Vec<String>` which lives until the closure is dropped. Then every call to the closure reborrows that mutable reference `&'call mut Vec<String>` which lives until the future is dropped (e.g. `await`ed).
|
||||
|
||||
As another example:
|
||||
|
||||
|
|
Loading…
Reference in New Issue