From d052363c6ae6ae1cf9f9143a863ac4c5b4a64a54 Mon Sep 17 00:00:00 2001 From: Max Orok Date: Mon, 6 Jul 2020 15:28:55 -0400 Subject: [PATCH] fix typo in Lifetimes mutable reference aliasing section --- src/lifetimes.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lifetimes.md b/src/lifetimes.md index 649cd77..c6c0e84 100644 --- a/src/lifetimes.md +++ b/src/lifetimes.md @@ -213,7 +213,7 @@ understand `Vec` at all. What it *does* see is that `x` has to live for `'b` to be printed. The signature of `Index::index` subsequently demands that the reference we take to `data` has to survive for `'b`. When we try to call `push`, it then sees us try to make an `&'c mut data`. Rust knows that `'c` is contained -within `'b`, and rejects our program because the `&'b data` must still be live! +within `'b`, and rejects our program because the `&'b data` must still be alive! Here we see that the lifetime system is much more coarse than the reference semantics we're actually interested in preserving. For the most part, *that's