rust/src/test/run-pass/yield1.rs
2012-02-20 18:58:04 -08:00

16 lines
281 B
Rust

// -*- rust -*-
use std;
import task;
import task::*;
fn main() {
let builder = task::mk_task_builder();
let result = task::future_result(builder);
task::run(builder) {|| child(); }
#error("1");
yield();
future::get(result);
}
fn child() { #error("2"); }