-
Couldn't load subscription status.
- Fork 13.9k
Closed
Description
When running the following code, printing to stdout, and other I/O fails to work.
extern crate green;
extern crate rustuv;
use self::green::{SchedPool, PoolConfig, GreenTaskBuilder};
use std::task::{TaskBuilder};
fn main() {
let mut pool = SchedPool::new(PoolConfig::new());
{
let tb = TaskBuilder::new().green(&mut pool);
let res = tb.try_future(proc() {
println!("test")
});
let _ = res.unwrap();
}
pool.shutdown();
}The code is based on: http://doc.rust-lang.org/green/index.html#using-a-scheduler-pool
Resulting error:
task '<unnamed>' failed at 'called `Result::unwrap()` on an `Err` value: invalid argument', /home/robert/rust/src/libcore/result.rs:545
I was told to CC @alexcrichton.
Metadata
Metadata
Assignees
Labels
No labels