We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 6322fc2 + c6514df commit 551cc4bCopy full SHA for 551cc4b
src/scope/lifetime/explicit.md
@@ -40,7 +40,7 @@ fn failed_borrow<'a>() {
40
let _x = 12;
41
42
// ERROR: `_x` does not live long enough
43
- //let y: &'a i32 = &_x;
+ let y: &'a i32 = &_x;
44
// Attempting to use the lifetime `'a` as an explicit type annotation
45
// inside the function will fail because the lifetime of `&_x` is shorter
46
// than that of `y`. A short lifetime cannot be coerced into a longer one.
0 commit comments