diff --git a/src/libcore/slice/mod.rs b/src/libcore/slice/mod.rs index c69aafe687cf8..57bacdd99eff4 100644 --- a/src/libcore/slice/mod.rs +++ b/src/libcore/slice/mod.rs @@ -2817,6 +2817,7 @@ pub trait SliceIndex: private_slice_index::Sealed { /// performing any bounds checking. /// Calling this method with an out-of-bounds index is *[undefined behavior]* /// even if the resulting reference is not used. + /// /// [undefined behavior]: ../../reference/behavior-considered-undefined.html #[unstable(feature = "slice_index_methods", issue = "none")] unsafe fn get_unchecked(self, slice: &T) -> &Self::Output; @@ -2825,6 +2826,7 @@ pub trait SliceIndex: private_slice_index::Sealed { /// performing any bounds checking. /// Calling this method with an out-of-bounds index is *[undefined behavior]* /// even if the resulting reference is not used. + /// /// [undefined behavior]: ../../reference/behavior-considered-undefined.html #[unstable(feature = "slice_index_methods", issue = "none")] unsafe fn get_unchecked_mut(self, slice: &mut T) -> &mut Self::Output;