1 2 3 4 5 6 7 8 9 10 11
#![feature(plugin)] #![plugin(clippy)] #[deny(option_unwrap_used, result_unwrap_used)] fn main() { let opt = Some(0); let _ = opt.unwrap(); //~ERROR let res: Result<i32, ()> = Ok(0); let _ = res.unwrap(); //~ERROR }