Skip to main content

Module alloc

Module alloc 

Source
Expand description

Internal memory allocator implementation for rustc_public.

This module handles all direct interactions with rustc queries and performs the actual memory allocations. The stable interface in rustc_public::alloc delegates all query-related operations to this implementation.

Re-exportsยง

use rustc_abi::Size; ๐Ÿ”’
use rustc_abi::TyAndLayout; ๐Ÿ”’
use rustc_middle::mir::interpret::AllocId; ๐Ÿ”’
use rustc_middle::mir::interpret::AllocInit; ๐Ÿ”’
use rustc_middle::mir::interpret::AllocRange; ๐Ÿ”’
use rustc_middle::mir::interpret::Allocation; ๐Ÿ”’
use rustc_middle::mir::interpret::ConstAllocation; ๐Ÿ”’
use rustc_middle::mir::interpret::Pointer; ๐Ÿ”’
use rustc_middle::mir::interpret::Scalar; ๐Ÿ”’
use rustc_middle::mir::interpret::alloc_range; ๐Ÿ”’
use rustc_middle::ty::layout::HasTypingEnv; ๐Ÿ”’
use rustc_middle::ty::Ty; ๐Ÿ”’
use rustc_middle::ty::layout; ๐Ÿ”’
use super::CompilerCtxt; ๐Ÿ”’
use super::Tables; ๐Ÿ”’
use crate::bridge::Allocation as _; ๐Ÿ”’
use crate::Bridge; ๐Ÿ”’
use crate::Error; ๐Ÿ”’

Functionsยง

allocation_filter
Creates an Allocation only from information within the AllocRange.
create_ty_and_layout
try_new_indirect
try_new_scalar
try_new_slice