From ce04392d8d4f8cf14c70bbf1ad3544c7db4e1671 Mon Sep 17 00:00:00 2001 From: Yusuke Endoh Date: Wed, 4 Sep 2019 01:32:42 +0900 Subject: Propagate kw_splat information The kw_splat flag is whether the original call passes keyword or not. Some types of methods (e.g., bmethod and sym_proc) drops the information. This change tries to propagate the flag to the final callee, as far as I can. --- vm_core.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'vm_core.h') diff --git a/vm_core.h b/vm_core.h index 60c258e1f3..a679f0593f 100644 --- a/vm_core.h +++ b/vm_core.h @@ -255,6 +255,7 @@ struct rb_calling_info { VALUE block_handler; VALUE recv; int argc; + int kw_splat; }; struct rb_execution_context_struct; @@ -1627,7 +1628,7 @@ void rb_iseq_pathobj_set(const rb_iseq_t *iseq, VALUE path, VALUE realpath); int rb_ec_frame_method_id_and_class(const rb_execution_context_t *ec, ID *idp, ID *called_idp, VALUE *klassp); void rb_ec_setup_exception(const rb_execution_context_t *ec, VALUE mesg, VALUE cause); -VALUE rb_vm_invoke_proc(rb_execution_context_t *ec, rb_proc_t *proc, int argc, const VALUE *argv, VALUE block_handler); +VALUE rb_vm_invoke_proc(rb_execution_context_t *ec, rb_proc_t *proc, int argc, const VALUE *argv, int kw_splat, VALUE block_handler); VALUE rb_vm_make_proc_lambda(const rb_execution_context_t *ec, const struct rb_captured_block *captured, VALUE klass, int8_t is_lambda); static inline VALUE -- cgit v1.2.3