]> git.lizzy.rs Git - rust.git/blobdiff - library/core/src/marker.rs
fix various subst_identity vs skip_binder
[rust.git] / library / core / src / marker.rs
index c0fb954ce2d9d39c0a291902a021894ca820db2d..1326fc9ab096f03d6edde634db009dc697c17c15 100644 (file)
@@ -623,6 +623,12 @@ impl<T: ?Sized> !Sync for *mut T {}
 /// (ideally) or `PhantomData<*const T>` (if no lifetime applies), so
 /// as not to indicate ownership.
 ///
+/// ## Layout
+///
+/// For all `T`, the following are guaranteed:
+/// * `size_of::<PhantomData<T>>() == 0`
+/// * `align_of::<PhantomData<T>>() == 1`
+///
 /// [drop check]: ../../nomicon/dropck.html
 #[lang = "phantom_data"]
 #[stable(feature = "rust1", since = "1.0.0")]