From 20c3754739514b710a2e6744c9fd43bcb83c4706 Mon Sep 17 00:00:00 2001 From: Ralf Jung Date: Mon, 18 Jan 2016 19:18:26 +0100 Subject: [PATCH] mutable references wording --- src/part04.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/part04.rs b/src/part04.rs index 375ef9f..f2a6b6c 100644 --- a/src/part04.rs +++ b/src/part04.rs @@ -99,7 +99,7 @@ fn shared_ref_demo() { // ## Unique, mutable references //@ There is a second way to borrow something, a second kind of reference: The *mutable reference*. This is a reference that comes with the promise -//@ that nobody else has *any kind of access* to the referee - there is no aliasing. It is thus always safe to perform mutation through such a reference. +//@ that nobody else has *any kind of access* to the referee - in contrast to shared references, there is no aliasing with mutable references. It is thus always safe to perform mutation through such a reference. //@ Because there cannot be another reference to the same data, we could also call it a *unique* reference, but that is not their official name. //@ As an example, consider a function which increments every element of a vector by 1. -- 2.30.2