snarkvm_synthesizer_process

Trait StackEvaluate

Source
pub trait StackEvaluate<N: Network>: Clone {
    // Required methods
    fn evaluate_closure<A: Aleo<Network = N>>(
        &self,
        closure: &Closure<N>,
        inputs: &[Value<N>],
        call_stack: CallStack<N>,
        signer: Address<N>,
        caller: Address<N>,
        tvk: Field<N>,
    ) -> Result<Vec<Value<N>>>;
    fn evaluate_function<A: Aleo<Network = N>>(
        &self,
        call_stack: CallStack<N>,
        caller: Option<ProgramID<N>>,
    ) -> Result<Response<N>>;
}

Required Methods§

Source

fn evaluate_closure<A: Aleo<Network = N>>( &self, closure: &Closure<N>, inputs: &[Value<N>], call_stack: CallStack<N>, signer: Address<N>, caller: Address<N>, tvk: Field<N>, ) -> Result<Vec<Value<N>>>

Evaluates a program closure on the given inputs.

§Errors

This method will halt if the given inputs are not the same length as the input statements.

Source

fn evaluate_function<A: Aleo<Network = N>>( &self, call_stack: CallStack<N>, caller: Option<ProgramID<N>>, ) -> Result<Response<N>>

Evaluates a program function on the given inputs.

§Errors

This method will halt if the given inputs are not the same length as the input statements.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§