diff options
Diffstat (limited to 'src/liballoc')
| -rw-r--r-- | src/liballoc/arc.rs | 3 | ||||
| -rw-r--r-- | src/liballoc/rc.rs | 3 |
2 files changed, 5 insertions, 1 deletions
diff --git a/src/liballoc/arc.rs b/src/liballoc/arc.rs index e107d19a87c..f3b72e4a9ee 100644 --- a/src/liballoc/arc.rs +++ b/src/liballoc/arc.rs @@ -94,6 +94,9 @@ use heap::deallocate; /// With simple pipes, without `Arc`, a copy would have to be made for each /// task. /// +/// When you clone an `Arc<T>`, it will create another pointer to the data and +/// increase the reference counter. +/// /// ``` /// # #![feature(alloc, core)] /// use std::sync::Arc; diff --git a/src/liballoc/rc.rs b/src/liballoc/rc.rs index e0d7e32ecf5..7cdd4888426 100644 --- a/src/liballoc/rc.rs +++ b/src/liballoc/rc.rs @@ -431,7 +431,8 @@ impl<T> Clone for Rc<T> { /// Makes a clone of the `Rc<T>`. /// - /// This increases the strong reference count. + /// When you clone an `Rc<T>`, it will create another pointer to the data and + /// increase the strong reference counter. /// /// # Examples /// |
