rust/src/test/run-fail/unwind-partial-vec.rs

18 lines
287 B
Rust
Raw Normal View History

// error-pattern:fail
fn f() -> ~[int] { fail; }
// Voodoo. In unwind-alt we had to do this to trigger the bug. Might
// have been to do with memory allocation patterns.
fn prime() {
@0;
}
fn partial() {
let x = ~[~[0], f(), ~[0]];
}
fn main() {
prime();
partial();
}