rust/test-cargo-miri/src/main.rs

10 lines
226 B
Rust
Raw Normal View History

2017-06-29 12:59:47 -05:00
use byteorder::{BigEndian, ByteOrder};
fn main() {
2017-06-29 12:59:47 -05:00
let buf = &[1,2,3,4];
let n = <BigEndian as ByteOrder>::read_u32(buf);
assert_eq!(n, 0x01020304);
println!("{:#010x}", n);
2018-07-26 09:43:45 -05:00
eprintln!("standard error");
}