summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorJingwen <jin@users.noreply.github.com>2015-06-13 17:27:05 +0800
committerJingwen <jin@users.noreply.github.com>2015-06-13 17:27:05 +0800
commit337710e13d726b91fd6cdde9e58d8c0db24c73f0 (patch)
treeac6ace10a07ad7729a71f2aaf8de0385b9130d23
parent2359061733a648f14924e5d4083a67a49994aef9 (diff)
Fixed typo: changing an immutable ref will not compile
-rw-r--r--rust.html.markdown2
1 files changed, 1 insertions, 1 deletions
diff --git a/rust.html.markdown b/rust.html.markdown
index 17f7dc90..49303b0d 100644
--- a/rust.html.markdown
+++ b/rust.html.markdown
@@ -281,7 +281,7 @@ fn main() {
println!("{}", var); // Unlike `box`, `var` can still be used
println!("{}", *ref_var);
// var = 5; // this would not compile because `var` is borrowed
- // *ref_var = 6; // this would too, because `ref_var` is an immutable reference
+ // *ref_var = 6; // this would not too, because `ref_var` is an immutable reference
// Mutable reference
// While a value is mutably borrowed, it cannot be accessed at all.