2018-09-17 01:25:33 +02:00
|
|
|
#![feature(tool_lints)]
|
|
|
|
#![warn(clippy::all, clippy::style, clippy::mem_replace_option_with_none)]
|
|
|
|
|
|
|
|
use std::mem;
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
let mut an_option = Some(1);
|
|
|
|
let _ = mem::replace(&mut an_option, None);
|
2018-09-19 01:54:01 +02:00
|
|
|
let an_option = &mut Some(1);
|
|
|
|
let _ = mem::replace(an_option, None);
|
2018-09-17 01:25:33 +02:00
|
|
|
}
|