1
Fork 0

port over the tests to use the new API

This commit is contained in:
Niko Matsakis 2012-01-04 21:14:53 -08:00
parent 25e81e34ea
commit 9f84f88276
57 changed files with 202 additions and 186 deletions

View file

@ -11,14 +11,14 @@ fn test_cont() { let i = 0; while i < 1 { i += 1; let x: @int = cont; } }
fn test_ret() { let x: @int = ret; }
fn test_fail() {
fn f(&&_i: ()) { task::unsupervise(); let x: @int = fail; }
task::spawn((), f);
fn f() { task::unsupervise(); let x: @int = fail; }
task::spawn {|| f(); };
}
fn test_fail_indirect() {
fn f() -> ! { fail; }
fn g(&&_i: ()) { task::unsupervise(); let x: @int = f(); }
task::spawn((), g);
fn g() { task::unsupervise(); let x: @int = f(); }
task::spawn {|| g(); };
}
fn main() {