mirror of
https://github.com/rust-lang/rust
synced 2024-09-15 22:50:55 +00:00
rollup merge of #23906: steveklabnik/spellin
This commit is contained in:
commit
0cac5b6158
|
@ -477,7 +477,7 @@ forbidden in item signatures to allow reasoning about the types just based in
|
|||
the item signature alone. However, for ergonomic reasons a very restricted
|
||||
secondary inference algorithm called “lifetime elision” applies in function
|
||||
signatures. It infers only based on the signature components themselves and not
|
||||
based on the body of the function, only infers lifetime paramters, and does
|
||||
based on the body of the function, only infers lifetime parameters, and does
|
||||
this with only three easily memorizable and unambiguous rules. This makes
|
||||
lifetime elision a shorthand for writing an item signature, while not hiding
|
||||
away the actual types involved as full local inference would if applied to it.
|
||||
|
|
Loading…
Reference in a new issue