rust/tests/ui/illegal-ufcs-drop.rs
2023-01-11 09:32:08 +00:00

11 lines
160 B
Rust

// run-rustfix
struct Foo;
impl Drop for Foo {
fn drop(&mut self) {}
}
fn main() {
Drop::drop(&mut Foo) //~ ERROR explicit use of destructor method
}