We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 92e74f2 commit 0c82a1bCopy full SHA for 0c82a1b
library/core/src/intrinsics/mod.rs
@@ -2784,7 +2784,11 @@ pub const fn align_of<T>() -> usize;
2784
/// Therefore, implementations must not require the user to uphold
2785
/// any safety invariants.
2786
///
2787
+/// This intrinsic can only be evaluated at compile-time, and should only appear in
2788
+/// constants or inline const blocks.
2789
+///
2790
/// The stabilized version of this intrinsic is [`core::mem::offset_of`].
2791
+/// This intrinsic is also a lang item so `offset_of!` can desugar to calls to it.
2792
#[rustc_nounwind]
2793
#[unstable(feature = "core_intrinsics", issue = "none")]
2794
#[rustc_const_unstable(feature = "core_intrinsics", issue = "none")]
0 commit comments