Skip to content

Commit 375e7c5

Browse files
committed
More inline, doc fixes
1 parent 8f3cb7d commit 375e7c5

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

library/alloc/src/boxed.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,6 @@ impl<T> Box<T> {
269269
/// ```
270270
/// #![feature(allocator_api, new_uninit)]
271271
///
272-
///
273272
/// let mut five = Box::<u32>::try_new_uninit()?;
274273
///
275274
/// let five = unsafe {
@@ -284,6 +283,7 @@ impl<T> Box<T> {
284283
/// ```
285284
#[unstable(feature = "allocator_api", issue = "32838")]
286285
// #[unstable(feature = "new_uninit", issue = "63291")]
286+
#[inline]
287287
pub fn try_new_uninit() -> Result<Box<mem::MaybeUninit<T>>, AllocError> {
288288
Box::try_new_uninit_in(Global)
289289
}
@@ -309,6 +309,7 @@ impl<T> Box<T> {
309309
/// [zeroed]: mem::MaybeUninit::zeroed
310310
#[unstable(feature = "allocator_api", issue = "32838")]
311311
// #[unstable(feature = "new_uninit", issue = "63291")]
312+
#[inline]
312313
pub fn try_new_zeroed() -> Result<Box<mem::MaybeUninit<T>>, AllocError> {
313314
Box::try_new_zeroed_in(Global)
314315
}

library/alloc/src/sync.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -557,7 +557,7 @@ impl<T> Arc<T> {
557557
/// # Ok::<(), std::alloc::AllocError>(())
558558
/// ```
559559
///
560-
/// [zeroed]: ../../std/mem/union.MaybeUninit.html#method.zeroed
560+
/// [zeroed]: mem::MaybeUninit::zeroed
561561
#[unstable(feature = "allocator_api", issue = "32838")]
562562
// #[unstable(feature = "new_uninit", issue = "63291")]
563563
pub fn try_new_zeroed() -> Result<Arc<mem::MaybeUninit<T>>, AllocError> {

0 commit comments

Comments
 (0)