summaryrefslogtreecommitdiff
path: root/compile.c
diff options
context:
space:
mode:
authorS-H-GAMELINKS <gamelinks007@gmail.com>2021-08-31 20:30:35 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2021-09-05 23:01:27 +0900
commitbdd6d8746f0a07b2c0cc3a6b387bf594569c0bb7 (patch)
treef11d32da65e227763d598d765765a76ddace1a0a /compile.c
parent8f752c95d20134bcc0b5394f1cea723a40f1ac8c (diff)
Replace RBOOL macro
Notes
Notes: Merged: https://github.com/ruby/ruby/pull/4791
Diffstat (limited to 'compile.c')
-rw-r--r--compile.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/compile.c b/compile.c
index 90f0d87328..3d1ec62469 100644
--- a/compile.c
+++ b/compile.c
@@ -1654,7 +1654,7 @@ access_outer_variables(const rb_iseq_t *iseq, int level, ID id, bool write)
}
}
else {
- rb_id_table_insert(iseq->body->outer_variables, id, write ? Qtrue : Qfalse);
+ rb_id_table_insert(iseq->body->outer_variables, id, RBOOL(write));
}
iseq = iseq->body->parent_iseq;
@@ -5496,7 +5496,7 @@ setup_args_core(rb_iseq_t *iseq, LINK_ANCHOR *const args, const NODE *argn,
switch (nd_type(argn)) {
case NODE_SPLAT: {
NO_CHECK(COMPILE(args, "args (splat)", argn->nd_head));
- ADD_INSN1(args, argn, splatarray, dup_rest ? Qtrue : Qfalse);
+ ADD_INSN1(args, argn, splatarray, RBOOL(dup_rest));
if (flag) *flag |= VM_CALL_ARGS_SPLAT;
return INT2FIX(1);
}