Skip to main content

EvalContextExt

Trait EvalContextExt 

Source
pub trait EvalContextExt<'tcx>: MiriInterpCxExt<'tcx> {
    // Provided method
    fn block_thread_for_io(
        &mut self,
        source_fd: FileDescriptionRef<dyn WithSource>,
        interests: Interest,
        timeout: Option<(TimeoutClock, TimeoutAnchor, Duration)>,
        callback: DynUnblockCallback<'tcx>,
    ) { ... }
}

Provided Methods§

Source

fn block_thread_for_io( &mut self, source_fd: FileDescriptionRef<dyn WithSource>, interests: Interest, timeout: Option<(TimeoutClock, TimeoutAnchor, Duration)>, callback: DynUnblockCallback<'tcx>, )

Block the current thread until some interests on an I/O source are fulfilled or the optional timeout exceeded. The callback will be invoked when the thread gets unblocked.

There can be spurious wake-ups by the OS and thus it’s the callers responsibility to verify that the requested I/O interests are really ready and to block again if they’re not.

Implementors§

Source§

impl<'tcx> EvalContextExt<'tcx> for MiriInterpCx<'tcx>