#[lang_item]
for core::ptr::Unique
This commit is contained in:
parent
4996b56ba9
commit
dc3e91c6c2
@ -260,6 +260,8 @@ language_item_table! {
|
||||
EhCatchTypeinfo, sym::eh_catch_typeinfo, eh_catch_typeinfo, Target::Static, GenericRequirement::None;
|
||||
|
||||
OwnedBox, sym::owned_box, owned_box, Target::Struct, GenericRequirement::Minimum(1);
|
||||
// Experimental language item for Miri
|
||||
PtrUnique, sym::ptr_unique, ptr_unique, Target::Struct, GenericRequirement::Exact(1);
|
||||
|
||||
PhantomData, sym::phantom_data, phantom_data, Target::Struct, GenericRequirement::Exact(1);
|
||||
|
||||
|
@ -1156,6 +1156,7 @@ symbols! {
|
||||
ptr_null_mut,
|
||||
ptr_offset_from,
|
||||
ptr_offset_from_unsigned,
|
||||
ptr_unique,
|
||||
pub_macro_rules,
|
||||
pub_restricted,
|
||||
public,
|
||||
|
@ -32,6 +32,8 @@ use crate::ptr::NonNull;
|
||||
)]
|
||||
#[doc(hidden)]
|
||||
#[repr(transparent)]
|
||||
// Lang item used experimentally by Miri to define the semantics of `Unique`.
|
||||
#[cfg_attr(not(bootstrap), lang = "ptr_unique")]
|
||||
pub struct Unique<T: ?Sized> {
|
||||
pointer: NonNull<T>,
|
||||
// NOTE: this marker has no consequences for variance, but is necessary
|
||||
|
Loading…
x
Reference in New Issue
Block a user