diff options
| author | Corey Richardson <corey@octayn.net> | 2013-12-10 09:26:43 -0500 |
|---|---|---|
| committer | Corey Richardson <corey@octayn.net> | 2013-12-10 09:43:36 -0500 |
| commit | c8f47db8f54b78c917feb9729e3a30a870207fbf (patch) | |
| tree | 51592282103776d8ed8c8178b3a566b942083163 /doc/tutorial.md | |
| parent | fab5624eb6373d529f21309380ea467a8b4b5664 (diff) | |
| download | rust-c8f47db8f54b78c917feb9729e3a30a870207fbf.tar.gz rust-c8f47db8f54b78c917feb9729e3a30a870207fbf.zip | |
Update `Freeze` information
Diffstat (limited to 'doc/tutorial.md')
| -rw-r--r-- | doc/tutorial.md | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/doc/tutorial.md b/doc/tutorial.md index 74a02a12023..cea91d1f24f 100644 --- a/doc/tutorial.md +++ b/doc/tutorial.md @@ -1431,7 +1431,8 @@ For a more in-depth explanation of borrowed pointers, read the ## Freezing Lending an immutable pointer to an object freezes it and prevents mutation. -`Owned` objects have freezing enforced statically at compile-time. +`Freeze` objects have freezing enforced statically at compile-time. Examples +of non-`Freeze` types are `@mut` and [`RefCell<T>`][refcell]. ~~~~ let mut x = 5; @@ -1456,6 +1457,8 @@ let y = x; // the box is now unfrozen again ~~~~ +[refcell]: http://static.rust-lang.org/doc/master/std/cell/struct.RefCell.html + # Dereferencing pointers Rust uses the unary star operator (`*`) to access the contents of a |
