review updates
This commit is contained in:
parent
0d9c01480b
commit
c0d32fd2cc
1 changed files with 2 additions and 2 deletions
|
@ -1,5 +1,5 @@
|
|||
This error occurs when there is an unsatisfied outlives bound involving an
|
||||
elided region on a generic type parameter or associated type.
|
||||
elided region and a generic type parameter or associated type.
|
||||
|
||||
Erroneous code example:
|
||||
|
||||
|
@ -21,7 +21,7 @@ The compiler elides the lifetime of `x` and the return type to some arbitrary
|
|||
lifetime `'anon` in `no_restriction()`. The only information available to the
|
||||
compiler is that `'anon` is valid for the duration of the function. When
|
||||
calling `with_restriction()`, the compiler requires the completely unrelated
|
||||
type parameter `T` to outlive `'anon` because of the `T: 'a bound` in
|
||||
type parameter `T` to outlive `'anon` because of the `T: 'a` bound in
|
||||
`with_restriction()`. This causes an error because `T` is not required to
|
||||
outlive `'anon` in `no_restriction()`.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue