зеркало из https://github.com/github/ruby.git
should not restore builtin_inline_index
`builtin_inline_index` is restored because THEN clause on
`Primitive.mandatory_only?` was compiled twice.
However, f29c9d6d36
skips to compile THEN clause so we don't
need to restore `builtin_inline_index`.
This commit is contained in:
Родитель
fee9044b25
Коммит
e5a5e43c36
|
@ -8348,15 +8348,12 @@ compile_builtin_mandatory_only_method(rb_iseq_t *iseq, const NODE *node, const N
|
|||
.script_lines = ISEQ_BODY(iseq)->variable.script_lines,
|
||||
};
|
||||
|
||||
int prev_inline_index = GET_VM()->builtin_inline_index;
|
||||
|
||||
ISEQ_BODY(iseq)->mandatory_only_iseq =
|
||||
rb_iseq_new_with_opt(&ast, rb_iseq_base_label(iseq),
|
||||
rb_iseq_path(iseq), rb_iseq_realpath(iseq),
|
||||
nd_line(line_node), NULL, 0,
|
||||
ISEQ_TYPE_METHOD, ISEQ_COMPILE_DATA(iseq)->option);
|
||||
|
||||
GET_VM()->builtin_inline_index = prev_inline_index;
|
||||
ALLOCV_END(idtmp);
|
||||
return COMPILE_OK;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче