rust/tests/ui/option_take_on_temporary.fixed
infrandomness f8f144117d Swap span_lint for span_lint_and_sugg
This implements a machine applicable suggestion to any matched usage of
`.as_ref().take()``
2022-04-14 13:15:51 +02:00

8 lines
125 B
Rust

// run-rustfix
fn main() {
println!("Testing option_take_on_temporary");
let x = Some(3);
let y = x.as_ref();
}