Skip to content

Commit 8bfe289

Browse files
committed
Auto merge of #75932 - Amjad50:intra-doc-core-slice, r=jyn514
Use intra-doc links for `core/src/slice.mod.rs` partial help in #75080 r? @jyn514 - most are using primitive types links, which cannot be used with intra links at the moment - also `std` cannot be referenced in any link, `std::ptr::NonNull` and `std::slice` could not be referenced
2 parents 6c44bcc + 300a007 commit 8bfe289

File tree

1 file changed

+9
-10
lines changed

1 file changed

+9
-10
lines changed

library/core/src/slice/mod.rs

+9-10
Original file line numberDiff line numberDiff line change
@@ -5390,7 +5390,7 @@ unsafe impl<'a, T> TrustedRandomAccess for ChunksMut<'a, T> {
53905390
/// This struct is created by the [`chunks_exact`] method on [slices].
53915391
///
53925392
/// [`chunks_exact`]: ../../std/primitive.slice.html#method.chunks_exact
5393-
/// [`remainder`]: ../../std/slice/struct.ChunksExact.html#method.remainder
5393+
/// [`remainder`]: ChunksExact::remainder
53945394
/// [slices]: ../../std/primitive.slice.html
53955395
#[derive(Debug)]
53965396
#[stable(feature = "chunks_exact", since = "1.31.0")]
@@ -5530,7 +5530,7 @@ unsafe impl<'a, T> TrustedRandomAccess for ChunksExact<'a, T> {
55305530
/// This struct is created by the [`chunks_exact_mut`] method on [slices].
55315531
///
55325532
/// [`chunks_exact_mut`]: ../../std/primitive.slice.html#method.chunks_exact_mut
5533-
/// [`into_remainder`]: ../../std/slice/struct.ChunksExactMut.html#method.into_remainder
5533+
/// [`into_remainder`]: ChunksExactMut::into_remainder
55345534
/// [slices]: ../../std/primitive.slice.html
55355535
#[derive(Debug)]
55365536
#[stable(feature = "chunks_exact", since = "1.31.0")]
@@ -5667,7 +5667,7 @@ unsafe impl<'a, T> TrustedRandomAccess for ChunksExactMut<'a, T> {
56675667
/// This struct is created by the [`array_chunks`] method on [slices].
56685668
///
56695669
/// [`array_chunks`]: ../../std/primitive.slice.html#method.array_chunks
5670-
/// [`remainder`]: ../../std/slice/struct.ArrayChunks.html#method.remainder
5670+
/// [`remainder`]: ArrayChunks::remainder
56715671
/// [slices]: ../../std/primitive.slice.html
56725672
#[derive(Debug)]
56735673
#[unstable(feature = "array_chunks", issue = "74985")]
@@ -6072,7 +6072,7 @@ unsafe impl<'a, T> TrustedRandomAccess for RChunksMut<'a, T> {
60726072
/// This struct is created by the [`rchunks_exact`] method on [slices].
60736073
///
60746074
/// [`rchunks_exact`]: ../../std/primitive.slice.html#method.rchunks_exact
6075-
/// [`remainder`]: ../../std/slice/struct.ChunksExact.html#method.remainder
6075+
/// [`remainder`]: ChunksExact::remainder
60766076
/// [slices]: ../../std/primitive.slice.html
60776077
#[derive(Debug)]
60786078
#[stable(feature = "rchunks", since = "1.31.0")]
@@ -6217,7 +6217,7 @@ unsafe impl<'a, T> TrustedRandomAccess for RChunksExact<'a, T> {
62176217
/// This struct is created by the [`rchunks_exact_mut`] method on [slices].
62186218
///
62196219
/// [`rchunks_exact_mut`]: ../../std/primitive.slice.html#method.rchunks_exact_mut
6220-
/// [`into_remainder`]: ../../std/slice/struct.ChunksExactMut.html#method.into_remainder
6220+
/// [`into_remainder`]: ChunksExactMut::into_remainder
62216221
/// [slices]: ../../std/primitive.slice.html
62226222
#[derive(Debug)]
62236223
#[stable(feature = "rchunks", since = "1.31.0")]
@@ -6427,8 +6427,8 @@ unsafe impl<'a, T> TrustedRandomAccess for RChunksExactMut<'a, T> {
64276427
/// }
64286428
/// ```
64296429
///
6430-
/// [valid]: ../../std/ptr/index.html#safety
6431-
/// [`NonNull::dangling()`]: ../../std/ptr/struct.NonNull.html#method.dangling
6430+
/// [valid]: ptr#safety
6431+
/// [`NonNull::dangling()`]: ptr::NonNull::dangling
64326432
/// [`pointer::offset`]: ../../std/primitive.pointer.html#method.offset
64336433
#[inline]
64346434
#[stable(feature = "rust1", since = "1.0.0")]
@@ -6467,10 +6467,9 @@ pub unsafe fn from_raw_parts<'a, T>(data: *const T, len: usize) -> &'a [T] {
64676467
/// * The total size `len * mem::size_of::<T>()` of the slice must be no larger than `isize::MAX`.
64686468
/// See the safety documentation of [`pointer::offset`].
64696469
///
6470-
/// [valid]: ../../std/ptr/index.html#safety
6471-
/// [`NonNull::dangling()`]: ../../std/ptr/struct.NonNull.html#method.dangling
6470+
/// [valid]: ptr#safety
6471+
/// [`NonNull::dangling()`]: ptr::NonNull::dangling
64726472
/// [`pointer::offset`]: ../../std/primitive.pointer.html#method.offset
6473-
/// [`from_raw_parts`]: ../../std/slice/fn.from_raw_parts.html
64746473
#[inline]
64756474
#[stable(feature = "rust1", since = "1.0.0")]
64766475
pub unsafe fn from_raw_parts_mut<'a, T>(data: *mut T, len: usize) -> &'a mut [T] {

0 commit comments

Comments
 (0)