blob: 318ca54ffd63f3a86893846d80f29fd699823cf3 [file] [log] [blame]
//@ run-pass
use std::sync::mpsc::channel;
fn foo<F:FnOnce()+Send>(blk: F) {
blk();
}
pub fn main() {
let (tx, rx) = channel();
foo(move || {
tx.send(()).unwrap();
});
rx.recv().unwrap();
}