[][src]Trait rustc_data_structures::owning_ref::ToHandle

pub trait ToHandle {
    type Handle: Deref;
    unsafe fn to_handle(x: *const Self) -> Self::Handle;
}
⚙️ This is an internal compiler API. (rustc_private)

This crate is being loaded from the sysroot, a permanently unstable location for private compiler dependencies. It is not intended for general use. Prefer using a public version of this crate from crates.io via Cargo.toml.

Trait to implement the conversion of owner to handle for common types.

Associated Types

type Handle: Deref

⚙️ This is an internal compiler API. (rustc_private)

This crate is being loaded from the sysroot, a permanently unstable location for private compiler dependencies. It is not intended for general use. Prefer using a public version of this crate from crates.io via Cargo.toml.

The type of handle to be encapsulated by the OwningHandle.

Loading content...

Required methods

unsafe fn to_handle(x: *const Self) -> Self::Handle

⚙️ This is an internal compiler API. (rustc_private)

This crate is being loaded from the sysroot, a permanently unstable location for private compiler dependencies. It is not intended for general use. Prefer using a public version of this crate from crates.io via Cargo.toml.

Given an appropriately-long-lived pointer to ourselves, create a handle to be encapsulated by the OwningHandle.

Loading content...

Implementations on Foreign Types

impl<T: 'static> ToHandle for RefCell<T>[src]

type Handle = Ref<'static, T>

⚙️ This is an internal compiler API. (rustc_private)

This crate is being loaded from the sysroot, a permanently unstable location for private compiler dependencies. It is not intended for general use. Prefer using a public version of this crate from crates.io via Cargo.toml.

Loading content...

Implementors

Loading content...