rust/src/test/run-pass/unique-send.rs
2011-09-23 15:32:31 -07:00

11 lines
186 B
Rust

use std;
import std::comm;
import std::task;
fn main() {
let p = comm::port();
let c = comm::chan(p);
comm::send(c, ~100);
let v = comm::recv(p);
assert v == ~100;
}