Callable

Trait Callable 

Source
pub trait Callable<InputParameters, ReturnValue> {
    // Required method
    fn call(&self, parameters: InputParameters) -> RunResult<ReturnValue>;
}
Expand description

A trait for objects which may be called.

For example, these could be machine code programs associated with a particular calling convention ready for execution in an emulated environment, or they may be function pointers, or lisp expressions, etc.)

Required Methods§

Source

fn call(&self, parameters: InputParameters) -> RunResult<ReturnValue>

Calls the given callable object

Implementations on Foreign Types§

Source§

impl<InputParameters, ReturnValue> Callable<InputParameters, ReturnValue> for fn(InputParameters) -> RunResult<ReturnValue>

Source§

fn call(&self, parameters: InputParameters) -> RunResult<ReturnValue>

Implementors§

Source§

impl<InputParameters, ReturnType, T: Callable<InputParameters, ReturnType> + Clone + Disassemble> Callable<InputParameters, ReturnType> for Trace<T>

Source§

impl<Params: ParameterList, RetVal: ReturnValue> Callable<Params, RetVal> for Function<Params, RetVal>

Source§

impl<Params: Copy + Vals + Parameters, RetVal: Copy + Vals + ReturnValue> Callable<Params, RetVal> for O32<Params, RetVal>

Source§

impl<Params: ParameterList, RetVal: ReturnValue> Callable<Params, RetVal> for SdccCall1<Params, RetVal>