mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Follows callback declaration updates
This commit is contained in:
parent
4209066f0e
commit
6a0d2bc2af
4 changed files with 16 additions and 11 deletions
|
@ -114,7 +114,8 @@ static VALUE thread_spec_rb_thread_wait_for(VALUE self, VALUE s, VALUE ms) {
|
|||
}
|
||||
|
||||
|
||||
VALUE thread_spec_call_proc(VALUE arg_array) {
|
||||
VALUE thread_spec_call_proc(void *arg_ptr) {
|
||||
VALUE arg_array = (VALUE)arg_ptr;
|
||||
VALUE arg = rb_ary_pop(arg_array);
|
||||
VALUE proc = rb_ary_pop(arg_array);
|
||||
return rb_funcall(proc, rb_intern("call"), 1, arg);
|
||||
|
@ -125,7 +126,7 @@ static VALUE thread_spec_rb_thread_create(VALUE self, VALUE proc, VALUE arg) {
|
|||
rb_ary_push(args, proc);
|
||||
rb_ary_push(args, arg);
|
||||
|
||||
return rb_thread_create((VALUE (*)(void *))thread_spec_call_proc, (void*)args);
|
||||
return rb_thread_create(thread_spec_call_proc, (void*)args);
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue