summary refs log tree commit diff
path: root/src/test/run-fail/unwind-partial-unique.rs
blob: b7f5d1054eca79f6e167b5eaaaac1e57cf4ac874 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// 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 = ~f();
}

fn main() {
    prime();
    partial();
}