Skip to content

Commit

Permalink
Remove imemo type check for NODE
Browse files Browse the repository at this point in the history
In the past, `rb_iseq_compile_node` received `NODE *`
and `struct vm_ifunc *` as `node`. But after e743a35,
the function only receives `NODE *`.
This commit removes imemo type check to reduce the dependence
on `VALUE flags` of `struct RNode`.
  • Loading branch information
yui-knk committed Apr 6, 2024
1 parent dae5038 commit f022a70
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions compile.c
Expand Up @@ -869,10 +869,6 @@ rb_iseq_compile_node(rb_iseq_t *iseq, const NODE *node)
DECL_ANCHOR(ret);
INIT_ANCHOR(ret);

if (IMEMO_TYPE_P(node, imemo_ifunc)) {
rb_raise(rb_eArgError, "unexpected imemo_ifunc");
}

if (node == 0) {
NO_CHECK(COMPILE(ret, "nil", node));
iseq_set_local_table(iseq, 0);
Expand Down

0 comments on commit f022a70

Please sign in to comment.