[macruby-changes] [4812] MacRuby/trunk
source_changes at macosforge.org
source_changes at macosforge.org
Thu Oct 21 18:51:55 PDT 2010
Revision: 4812
http://trac.macosforge.org/projects/ruby/changeset/4812
Author: lsansonetti at apple.com
Date: 2010-10-21 18:51:53 -0700 (Thu, 21 Oct 2010)
Log Message:
-----------
fix a bug in Method#call where the method cache would not be used
Modified Paths:
--------------
MacRuby/trunk/proc.c
MacRuby/trunk/vm.h
Modified: MacRuby/trunk/proc.c
===================================================================
--- MacRuby/trunk/proc.c 2010-10-22 01:51:05 UTC (rev 4811)
+++ MacRuby/trunk/proc.c 2010-10-22 01:51:53 UTC (rev 4812)
@@ -1072,7 +1072,7 @@
}
}
- VALUE result = rb_vm_call2(NULL, data->recv, data->oclass, data->sel, argc, argv);
+ VALUE result = rb_vm_method_call(data, NULL, argc, argv);
if (safe >= 0) {
rb_set_safe_level_force(safe);
Modified: MacRuby/trunk/vm.h
===================================================================
--- MacRuby/trunk/vm.h 2010-10-22 01:51:05 UTC (rev 4811)
+++ MacRuby/trunk/vm.h 2010-10-22 01:51:53 UTC (rev 4812)
@@ -628,6 +628,15 @@
DISPATCH_FCALL, argc, argv);
}
+static inline VALUE
+rb_vm_method_call(rb_vm_method_t *m, rb_vm_block_t *block, int argc,
+ const VALUE *argv)
+{
+ return rb_vm_dispatch(rb_vm_current_vm(), (struct mcache *)m->cache, 0,
+ m->recv, (Class)m->oclass, m->sel, block, DISPATCH_FCALL,
+ argc, argv);
+}
+
VALUE rb_vm_yield_args(void *vm, int argc, const VALUE *argv);
static inline VALUE
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macruby-changes/attachments/20101021/2b788cc9/attachment.html>
More information about the macruby-changes
mailing list