[−][src]Trait rustc_middle::mir::interpret::allocation::AllocationExtra

pub trait AllocationExtra<Tag>: Debug + Clone {
    pub fn memory_read<'tcx>(
        _alloc: &Allocation<Tag, Self>,
        _ptr: Pointer<Tag>,
        _size: Size
    ) -> InterpResult<'tcx> { ... }
pub fn memory_written<'tcx>(
        _alloc: &mut Allocation<Tag, Self>,
        _ptr: Pointer<Tag>,
        _size: Size
    ) -> InterpResult<'tcx> { ... }
pub fn memory_deallocated<'tcx>(
        _alloc: &mut Allocation<Tag, Self>,
        _ptr: Pointer<Tag>,
        _size: Size
    ) -> InterpResult<'tcx> { ... } }

Provided methods

pub fn memory_read<'tcx>(
    _alloc: &Allocation<Tag, Self>,
    _ptr: Pointer<Tag>,
    _size: Size
) -> InterpResult<'tcx>
[src]

Hook for performing extra checks on a memory read access.

Takes read-only access to the allocation so we can keep all the memory read operations take &self. Use a RefCell in AllocExtra if you need to mutate.

pub fn memory_written<'tcx>(
    _alloc: &mut Allocation<Tag, Self>,
    _ptr: Pointer<Tag>,
    _size: Size
) -> InterpResult<'tcx>
[src]

Hook for performing extra checks on a memory write access.

pub fn memory_deallocated<'tcx>(
    _alloc: &mut Allocation<Tag, Self>,
    _ptr: Pointer<Tag>,
    _size: Size
) -> InterpResult<'tcx>
[src]

Hook for performing extra checks on a memory deallocation. size will be the size of the allocation.

Loading content...

Implementations on Foreign Types

impl AllocationExtra<()> for ()[src]

Loading content...

Implementors

Loading content...