Files
parity-wasm/src/builder/invoke.rs

15 lines
214 B
Rust
Raw Normal View History

2017-04-06 11:34:31 +03:00
//! invoke helper
pub trait Invoke<A> {
type Result;
fn invoke(self, arg: A) -> Self::Result;
}
pub struct Identity;
impl<A> Invoke<A> for Identity {
type Result = A;
fn invoke(self, arg: A) -> A { arg }
}