pub fn eval_contract<T, R>(params: &CallParams<T, ReturnType<R>>) -> Result<R>
where
    T: EnvTypes,
    R: scale::Decode,
{
    <EnvInstance as OnInstance>::on_instance(|instance| {
        TypedEnv::eval_contract::<T, R>(instance, params)
    })
}
/// Evaluates a contract message and returns its result.
///
/// # Note
///
/// This is a low level way to evaluate another smart contract.
/// Prefer to use the ink! guided and type safe approach to using this.
///
/// # Errors
///
/// - If the called contract does not exist.
/// - If the called contract is a tombstone.
/// - If arguments passed to the called contract message are invalid.
/// - If the called contract execution has trapped.
/// - If the called contract ran out of gas upon execution.
/// - If the returned value failed to decode properly.
Evaluates a contract message and returns its result.
Evaluates a contract message and returns its result .
pub fn eval_contract<T, R>(params: &CallParams<T, ReturnType<R>>) -> Result<R>
where
    T: EnvTypes,
    R: scale::Decode,
{
    <EnvInstance as OnInstance>::on_instance(|instance| {
        TypedEnv::eval_contract::<T, R>(instance, params)
    })
}
pub fn eval_contract < T , R > ( params : & CallParams < T , ReturnType < R > > ) -> Result < R > where T : EnvTypes , R : scale :: Decode , { < EnvInstance as OnInstance > :: on_instance ( | instance | { TypedEnv :: eval_contract :: < T , R > ( instance , params ) } ) }
Evaluates a contract message and returns its result.
Evaluates a contract message and returns its result .
params
&CallParams<T, ReturnType<R>>
params
&CallParams<T, ReturnType<R>>
note
This is a low level way to evaluate another smart contract.
Prefer to use the ink. guided and type safe approach to using this.
This is a low level way to evaluate another smart contract . Prefer to use the ink . guided and type safe approach to using this .
errors
If the called contract does not exist.
If the called contract is a tombstone.
If arguments passed to the called contract message are invalid.
If the called contract execution has trapped.
If the called contract ran out of gas upon execution.
If the returned value failed to decode properly.
If the called contract does not exist . If the called contract is a tombstone . If arguments passed to the called contract message are invalid . If the called contract execution has trapped . If the called contract ran out of gas upon execution . If the returned value failed to decode properly .