Rollup merge of #103136 - tmccombs:alignment-doc-fixes, r=Dylan-DPC
Fix types in documentation for `Alignment::as_usize` and `Alignmnet::as_nonzero`
This commit is contained in:
commit
0c2017ff54
1 changed files with 2 additions and 2 deletions
|
@ -83,7 +83,7 @@ impl Alignment {
|
|||
unsafe { mem::transmute::<usize, Alignment>(align) }
|
||||
}
|
||||
|
||||
/// Returns the alignment as a [`NonZeroUsize`]
|
||||
/// Returns the alignment as a [`usize`]
|
||||
#[unstable(feature = "ptr_alignment_type", issue = "102070")]
|
||||
#[rustc_const_unstable(feature = "ptr_alignment_type", issue = "102070")]
|
||||
#[inline]
|
||||
|
@ -91,7 +91,7 @@ impl Alignment {
|
|||
self.0 as usize
|
||||
}
|
||||
|
||||
/// Returns the alignment as a [`usize`]
|
||||
/// Returns the alignment as a [`NonZeroUsize`]
|
||||
#[unstable(feature = "ptr_alignment_type", issue = "102070")]
|
||||
#[inline]
|
||||
pub const fn as_nonzero(self) -> NonZeroUsize {
|
||||
|
|
Loading…
Add table
Reference in a new issue