referrerpolicy=no-referrer-when-downgrade

Function precompile

Source
pub fn precompile<P, E>(
    ext: &mut E,
    address: &[u8; 20],
    input: &P::Interface,
) -> Result<Vec<u8>, Error>
where P: Precompile<T = E::T>, E: ExtWithInfo,
Expand description

Convenience function to run pre-compiles for testing or benchmarking purposes.

Use CallSetup to create an appropriate environment to pass as the ext parameter. Panics in case the MATCHER of P does not match the passed address.