1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
trait SipHash { fn reset(&self); } fn siphash(k0 : u64) { struct SipState { v0: u64, } impl SipHash for SipState { fn reset(&self) { self.v0 = k0 ^ 0x736f6d6570736575; //~ ERROR can't capture dynamic environment } } panic!(); } fn main() {}