Struct rustc::mir::interpret::AllocMap [−][src]
pub struct AllocMap<'tcx, M> { id_to_type: FxHashMap<AllocId, AllocType<'tcx, M>>, type_interner: FxHashMap<AllocType<'tcx, M>, AllocId>, next_id: AllocId, }
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Fields
id_to_type: FxHashMap<AllocId, AllocType<'tcx, M>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Lets you know what an AllocId refers to
type_interner: FxHashMap<AllocType<'tcx, M>, AllocId>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Used to ensure that functions and statics only get one associated AllocId
next_id: AllocId
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
The AllocId to assign to the next requested id. Always incremented, never gets smaller.
Methods
impl<'tcx, M: Debug + Eq + Hash + Clone> AllocMap<'tcx, M>
[src]
impl<'tcx, M: Debug + Eq + Hash + Clone> AllocMap<'tcx, M>
pub fn new() -> Self
[src]
pub fn new() -> Self
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn reserve(&mut self) -> AllocId
[src]
pub fn reserve(&mut self) -> AllocId
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
obtains a new allocation ID that can be referenced but does not yet have an allocation backing it.
fn intern(&mut self, alloc_type: AllocType<'tcx, M>) -> AllocId
[src]
fn intern(&mut self, alloc_type: AllocType<'tcx, M>) -> AllocId
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn create_fn_alloc(&mut self, instance: Instance<'tcx>) -> AllocId
[src]
pub fn create_fn_alloc(&mut self, instance: Instance<'tcx>) -> AllocId
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn get(&self, id: AllocId) -> Option<AllocType<'tcx, M>>
[src]
pub fn get(&self, id: AllocId) -> Option<AllocType<'tcx, M>>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn unwrap_memory(&self, id: AllocId) -> M
[src]
pub fn unwrap_memory(&self, id: AllocId) -> M
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn intern_static(&mut self, static_id: DefId) -> AllocId
[src]
pub fn intern_static(&mut self, static_id: DefId) -> AllocId
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn allocate(&mut self, mem: M) -> AllocId
[src]
pub fn allocate(&mut self, mem: M) -> AllocId
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn set_id_memory(&mut self, id: AllocId, mem: M)
[src]
pub fn set_id_memory(&mut self, id: AllocId, mem: M)
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn set_id_same_memory(&mut self, id: AllocId, mem: M)
[src]
pub fn set_id_same_memory(&mut self, id: AllocId, mem: M)
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?