summaryrefslogtreecommitdiff
path: root/iseq.c
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-06-24 07:29:21 +0000
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-06-24 07:29:21 +0000
commit68e02f2c2cc98e6ab736b3122aafe7a2398642f6 (patch)
tree2167a1299cd58748a883b72de1ba8de0b4128df6 /iseq.c
parenta5c9bf7d63bff7772d7a3b392e9d5ebe6a0bf479 (diff)
* vm.c (callee_setup_arg): added. support correct post arg.
* vm_macro.def (macro_eval_invoke_func): fix to use callee_setup_arg. * compile.c (set_arguments): adjust for above changes. * compile.c (iseq_compile_each): ditto. * iseq.c (ruby_iseq_disasm): ditto. * yarvcore.h: add rb_iseq_t#post_arg_start and arg_size. * bootstraptest/test_method.rb: add post arg tests. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12594 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'iseq.c')
-rw-r--r--iseq.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/iseq.c b/iseq.c
index 8fe442316c..9e66f9b8ce 100644
--- a/iseq.c
+++ b/iseq.c
@@ -782,11 +782,13 @@ ruby_iseq_disasm(VALUE self)
}
}
- snprintf(argi, sizeof(argi), "%s%s%s%s", /* arg, opts, rest, block */
+ snprintf(argi, sizeof(argi), "%s%s%s%s%s", /* arg, opts, rest, post block */
iseqdat->argc > i ? "Arg" : "",
opti,
- iseqdat->arg_rest - d == i ? "Rest" : "",
- iseqdat->arg_block - d == i ? "Block" : "");
+ iseqdat->arg_rest == i ? "Rest" : "",
+ (iseqdat->arg_post_start <= i &&
+ i < iseqdat->arg_post_start + iseqdat->arg_post_len) ? "Post" : "",
+ iseqdat->arg_block == i ? "Block" : "");
snprintf(info, sizeof(info), "%s%s%s%s", name ? name : "?",
*argi ? "<" : "", argi, *argi ? ">" : "");