Merge pull request #6282 from dearblue/orphan-block

Delegate the care of a directly given block from `cipop()` to `cipush()`
This commit is contained in:
Yukihiro "Matz" Matsumoto
2024-06-02 22:02:58 +09:00
committed by GitHub
3 changed files with 26 additions and 9 deletions
+1 -1
View File
@@ -176,9 +176,9 @@ typedef struct {
uint8_t n:4; /* (15=*) c=n|nk<<4 */
uint8_t nk:4; /* (15=*) */
uint8_t cci; /* called from C function */
uint8_t flags; /* MRB_CI_COMPANION_BLOCK or zero */
mrb_sym mid;
const struct RProc *proc;
struct RProc *blk;
mrb_value *stack;
const mrb_code *pc; /* current address on iseq of this proc */
union {
+3
View File
@@ -195,6 +195,9 @@ mrb_value mrb_obj_instance_eval(mrb_state*, mrb_value);
mrb_value mrb_mod_module_eval(mrb_state*, mrb_value);
mrb_value mrb_f_send(mrb_state *mrb, mrb_value self);
/* mrb_callinfo::flags */
#define MRB_CI_COMPANION_BLOCK 0x01 /* it means `method { ... }`, not `method(&blk)` */
#ifdef MRB_USE_BIGINT
mrb_value mrb_bint_new_int(mrb_state *mrb, mrb_int x);
#ifdef MRB_INT64