diff options
| author | Brian Anderson <banderson@mozilla.com> | 2012-02-14 22:23:16 -0800 |
|---|---|---|
| committer | Brian Anderson <banderson@mozilla.com> | 2012-02-16 11:12:22 -0800 |
| commit | b2cfb7ef8262ebe47514f016f59054ebcfe15d61 (patch) | |
| tree | 871bc0980b26b11d700761cad9a8ac245f5fcedc /src/rt/rust_builtin.cpp | |
| parent | e62ddf48988087d19934e1fdc6abb6de5f7a6a02 (diff) | |
| download | rust-b2cfb7ef8262ebe47514f016f59054ebcfe15d61.tar.gz rust-b2cfb7ef8262ebe47514f016f59054ebcfe15d61.zip | |
rt: Add rust_port_select function
Diffstat (limited to 'src/rt/rust_builtin.cpp')
| -rw-r--r-- | src/rt/rust_builtin.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/rt/rust_builtin.cpp b/src/rt/rust_builtin.cpp index 628389f10ce..ecc73204f29 100644 --- a/src/rt/rust_builtin.cpp +++ b/src/rt/rust_builtin.cpp @@ -594,6 +594,14 @@ port_recv(uintptr_t *dptr, rust_port *port, } extern "C" CDECL void +rust_port_select(rust_port **dptr, rust_port **ports, + size_t n_ports, uintptr_t *yield) { + rust_task *task = rust_task_thread::get_task(); + rust_port_selector *selector = task->get_port_selector(); + selector->select(task, dptr, ports, n_ports, yield); +} + +extern "C" CDECL void rust_set_exit_status(intptr_t code) { rust_task *task = rust_task_thread::get_task(); task->kernel->set_exit_status((int)code); |
