diff options
| author | bors <bors@rust-lang.org> | 2016-09-30 11:08:58 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2016-09-30 11:08:58 -0700 |
| commit | 50932b5f4e3a5f1b6c955100da5b30d77bcd29d3 (patch) | |
| tree | dbce305f5d8ea4c390a3aa27831a7756e6b22981 /src/liballoc | |
| parent | 954873055a998a06841ac19b39b1fe18a6641731 (diff) | |
| parent | af1df9880f603320bde62c8786f2208d659ce8ae (diff) | |
| download | rust-50932b5f4e3a5f1b6c955100da5b30d77bcd29d3.tar.gz rust-50932b5f4e3a5f1b6c955100da5b30d77bcd29d3.zip | |
Auto merge of #36864 - steveklabnik:rollup, r=steveklabnik
Rollup of 13 pull requests - Successful merges: #36529, #36535, #36576, #36623, #36711, #36750, #36810, #36829, #36833, #36841, #36842, #36851, #36860 - Failed merges:
Diffstat (limited to 'src/liballoc')
| -rw-r--r-- | src/liballoc/boxed.rs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/liballoc/boxed.rs b/src/liballoc/boxed.rs index bc9b6e805ef..28f4dda1408 100644 --- a/src/liballoc/boxed.rs +++ b/src/liballoc/boxed.rs @@ -244,12 +244,14 @@ impl<T: ?Sized> Box<T> { /// the destructor of `T` and free the allocated memory. Since the /// way `Box` allocates and releases memory is unspecified, the /// only valid pointer to pass to this function is the one taken - /// from another `Box` via the `Box::into_raw` function. + /// from another `Box` via the [`Box::into_raw`] function. /// /// This function is unsafe because improper use may lead to /// memory problems. For example, a double-free may occur if the /// function is called twice on the same raw pointer. /// + /// [`Box::into_raw`]: struct.Box.html#method.into_raw + /// /// # Examples /// /// ``` @@ -269,12 +271,14 @@ impl<T: ?Sized> Box<T> { /// memory previously managed by the `Box`. In particular, the /// caller should properly destroy `T` and release the memory. The /// proper way to do so is to convert the raw pointer back into a - /// `Box` with the `Box::from_raw` function. + /// `Box` with the [`Box::from_raw`] function. /// /// Note: this is an associated function, which means that you have /// to call it as `Box::into_raw(b)` instead of `b.into_raw()`. This /// is so that there is no conflict with a method on the inner type. /// + /// [`Box::from_raw`]: struct.Box.html#method.from_raw + /// /// # Examples /// /// ``` |
