Do not warn unused block when using forwarding

Fixes [Bug #21003]
This commit is contained in:
Kevin Newton 2025-01-05 13:29:55 -05:00
parent c037f5a28c
commit 2a1cff40f5
Notes: git 2025-01-06 00:56:42 +00:00
2 changed files with 10 additions and 0 deletions

View file

@ -1756,6 +1756,8 @@ pm_setup_args_core(const pm_arguments_node_t *arguments_node, const pm_node_t *b
break;
}
case PM_FORWARDING_ARGUMENTS_NODE: { // not counted in argc return value
iseq_set_use_block(ISEQ_BODY(iseq)->local_iseq);
if (ISEQ_BODY(ISEQ_BODY(iseq)->local_iseq)->param.flags.forwardable) {
*flags |= VM_CALL_FORWARDING;