rust/tests/target/fn_once.rs
2018-03-02 15:07:13 +13:00

8 lines
175 B
Rust

struct Add(usize);
impl FnOnce<(usize,)> for Add {
type Output = Add;
extern "rust-call" fn call_once(self, to: (usize,)) -> Add {
Add(self.0 + to.0)
}
}