rust/src/test/compile-fail/issue-2825-b.rs

18 lines
261 B
Rust
Raw Normal View History

2012-08-15 18:46:55 -07:00
struct example {
let x: int;
drop {} //~ ERROR First destructor declared
drop {
debug!("Goodbye, cruel world");
}
}
2012-09-05 15:58:43 -07:00
fn example() -> example {
example {
x: 1
}
}
fn main(_args: ~[~str]) {
let e: example = example();
}