2012-12-10 17:32:48 -08:00
|
|
|
// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
|
|
|
|
// file at the top-level directory of this distribution and at
|
|
|
|
// http://rust-lang.org/COPYRIGHT.
|
|
|
|
//
|
|
|
|
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
|
|
|
|
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
|
|
|
|
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
|
|
|
|
// option. This file may not be copied, modified, or distributed
|
|
|
|
// except according to those terms.
|
|
|
|
|
2013-05-20 17:07:24 -07:00
|
|
|
extern mod extra;
|
2012-07-26 14:04:03 -07:00
|
|
|
|
|
|
|
fn siphash(k0 : u64) {
|
|
|
|
|
2012-08-15 18:46:55 -07:00
|
|
|
struct siphash {
|
2013-02-22 16:08:16 -08:00
|
|
|
v0: u64,
|
2012-09-07 19:04:40 -07:00
|
|
|
}
|
|
|
|
|
2013-05-31 15:17:22 -07:00
|
|
|
impl siphash {
|
|
|
|
pub fn reset(&mut self) {
|
2013-07-01 23:17:43 +05:30
|
|
|
self.v0 = k0 ^ 0x736f6d6570736575; //~ ERROR can't capture dynamic environment
|
2013-05-10 18:52:56 +02:00
|
|
|
//~^ ERROR unresolved name `k0`.
|
2012-07-26 14:04:03 -07:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|