mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-16 21:15:18 +03:00
@@ -512,6 +512,11 @@ fn ge(&self, other: &*mut T) -> bool { *self >= *other }
|
||||
#[unstable(feature = "unique", reason = "needs an RFC to flesh out design")]
|
||||
pub struct Unique<T: ?Sized> {
|
||||
pointer: NonZero<*const T>,
|
||||
// NOTE: this marker has no consequences for variance, but is necessary
|
||||
// for dropck to understand that we logically own a `T`.
|
||||
//
|
||||
// For details, see:
|
||||
// https://github.com/rust-lang/rfcs/blob/master/text/0769-sound-generic-drop.md#phantom-data
|
||||
_marker: PhantomData<T>,
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user