fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1#![warn(clippy::empty_drop)] 2#![allow(unused)] 3 4// should cause an error 5struct Foo; 6 7 8 9// shouldn't cause an error 10struct Bar; 11 12impl Drop for Bar { 13 fn drop(&mut self) { 14 println!("dropping bar!"); 15 } 16} 17 18// should error 19struct Baz; 20 21 22 23fn main() {}