RBOOL is unnecessary in C boolean context

Fix a `-Wint-in-bool-context` warning.

```
proc.c:688:33: warning: '?:' using integer constants in boolean context [-Wint-in-bool-context]
  688 |     if (RBOOL(get_local_variable_ptr(&env, idItImplicit, FALSE))) {
```
This commit is contained in:
Nobuyoshi Nakada 2025-12-18 15:42:36 +09:00 committed by Nobuyoshi Nakada
parent 74b18b5382
commit 85ff21c9e5
Notes: git 2025-12-18 07:42:47 +00:00

2
proc.c
View File

@ -685,7 +685,7 @@ bind_implicit_parameters(VALUE bindval)
GetBindingPtr(bindval, bind);
env = VM_ENV_ENVVAL_PTR(vm_block_ep(&bind->block));
if (RBOOL(get_local_variable_ptr(&env, idItImplicit, FALSE))) {
if (get_local_variable_ptr(&env, idItImplicit, FALSE)) {
return rb_ary_new_from_args(1, ID2SYM(idIt));
}