diff options
| author | unknown <Eric@.(none)> | 2011-08-08 13:38:20 -0700 |
|---|---|---|
| committer | Eric Holk <eholk@mozilla.com> | 2011-08-08 16:55:38 -0700 |
| commit | 44bef5f2cb175769155d92ec65bd6b16e6708a1e (patch) | |
| tree | d7524b51e2af0cb191cd93cda3f282ac4ac8f4c6 /src/rt/test/rust_test_runtime.cpp | |
| parent | f4f057ced1f4152575571a6e5116e1ad5bb38beb (diff) | |
| download | rust-44bef5f2cb175769155d92ec65bd6b16e6708a1e.tar.gz rust-44bef5f2cb175769155d92ec65bd6b16e6708a1e.zip | |
Introduced task handles.
This is the new way to refer to tasks in rust-land. Currently all they do is serve as a key to look up the old rust_task structure. Ideally they won't be ref counted, but baby steps.
Diffstat (limited to 'src/rt/test/rust_test_runtime.cpp')
| -rw-r--r-- | src/rt/test/rust_test_runtime.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/rt/test/rust_test_runtime.cpp b/src/rt/test/rust_test_runtime.cpp index ad5a018eec8..520426eb256 100644 --- a/src/rt/test/rust_test_runtime.cpp +++ b/src/rt/test/rust_test_runtime.cpp @@ -45,7 +45,8 @@ void task_entry() { void rust_task_test::worker::run() { - rust_task *root_task = kernel->create_task(NULL, "main"); + rust_task_id root_id = kernel->create_task(NULL, "main"); + rust_task *root_task = kernel->get_task_by_id(root_id); root_task->start((uintptr_t)&task_entry, (uintptr_t)NULL); root_task->sched->start_main_loop(); } |
