diff options
| author | Tom Lee <github@tomlee.co> | 2013-05-21 23:17:04 -0700 |
|---|---|---|
| committer | Tom Lee <github@tomlee.co> | 2013-05-27 17:13:01 -0700 |
| commit | 67283eaad2f53e19ae963e2b0a04b65826568336 (patch) | |
| tree | 4224fafe84f9b4c22b032acddbcd9490149a5229 /src/rt/rust_task.cpp | |
| parent | dbc57584bd4e87f0bd3eed6bced8bbd04d99edcf (diff) | |
| download | rust-67283eaad2f53e19ae963e2b0a04b65826568336.tar.gz rust-67283eaad2f53e19ae963e2b0a04b65826568336.zip | |
Omit unused implicit argument if return type is immediate.
Diffstat (limited to 'src/rt/rust_task.cpp')
| -rw-r--r-- | src/rt/rust_task.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/rt/rust_task.cpp b/src/rt/rust_task.cpp index 266c0652c6e..28d36a4bf88 100644 --- a/src/rt/rust_task.cpp +++ b/src/rt/rust_task.cpp @@ -162,9 +162,7 @@ void task_start_wrapper(spawn_args *a) bool threw_exception = false; try { - // The first argument is the return pointer; as the task fn - // must have void return type, we can safely pass 0. - a->f(0, a->envptr, a->argptr); + a->f(a->envptr, a->argptr); } catch (rust_task *ex) { assert(ex == task && "Expected this task to be thrown for unwinding"); threw_exception = true; @@ -185,7 +183,7 @@ void task_start_wrapper(spawn_args *a) if(env) { // free the environment (which should be a unique closure). const type_desc *td = env->td; - td->drop_glue(NULL, NULL, NULL, box_body(env)); + td->drop_glue(NULL, NULL, box_body(env)); task->kernel->region()->free(env); } |
