File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed
compiler/rustc_data_structures/src Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -4,6 +4,8 @@ use std::ptr::Alignment;
4
4
///
5
5
/// This is equivalent to [`mem::align_of`], but also works for some unsized
6
6
/// types (e.g. slices or rustc's `List`s).
7
+ ///
8
+ /// [`mem::align_of`]: std::mem::align_of
7
9
pub const fn align_of < T : ?Sized + Aligned > ( ) -> Alignment {
8
10
T :: ALIGN
9
11
}
@@ -16,7 +18,7 @@ pub const fn align_of<T: ?Sized + Aligned>() -> Alignment {
16
18
/// is [`mem::align_of<Self>()`], for unsized types it depends on the type, for
17
19
/// example `[T]` has alignment of `T`.
18
20
///
19
- /// [`mem::align_of<Self>()`]: mem::align_of
21
+ /// [`mem::align_of<Self>()`]: std:: mem::align_of
20
22
pub unsafe trait Aligned {
21
23
/// Alignment of `Self`.
22
24
const ALIGN : Alignment ;
You can’t perform that action at this time.
0 commit comments