Its gen_constant_list(o) returns an OP*, but the thing it returns is
currently always o.
So just assume it returns it arg.
This will shortly make making Perl_list() non-recursive easier.
Ap |char* |vform |NN const char* pat|NULLOK va_list* args
Ap |void |free_tmps
#if defined(PERL_IN_OP_C)
-S |OP* |gen_constant_list|NULLOK OP* o
+S |void |gen_constant_list|NULLOK OP* o
#endif
#if !defined(HAS_GETENV_LEN)
: Used in hv.c
/* possibly flatten 1..10 into a constant array */
if (!o->op_next && cUNOPo->op_first->op_type == OP_FLOP) {
list(cBINOPo->op_first);
- return gen_constant_list(o);
+ gen_constant_list(o);
+ return o;
}
listkids(o);
break;
* the constant value being an AV holding the flattened range.
*/
-static OP *
+static void
S_gen_constant_list(pTHX_ OP *o)
{
dVAR;
list(o);
if (PL_parser && PL_parser->error_count)
- return o; /* Don't attempt to run with errors */
+ return; /* Don't attempt to run with errors */
curop = LINKLIST(o);
old_next = o->op_next;
delete_eval_scope();
}
if (ret)
- return o;
+ return;
OpTYPE_set(o, OP_RV2AV);
o->op_flags &= ~OPf_REF; /* treat \(1..2) like an ordinary list */
SvREADONLY_on(*svp);
}
LINKLIST(o);
- return list(o);
+ list(o);
+ return;
}
/*
STATIC void S_forget_pmop(pTHX_ PMOP *const o);
#define PERL_ARGS_ASSERT_FORGET_PMOP \
assert(o)
-STATIC OP* S_gen_constant_list(pTHX_ OP* o);
+STATIC void S_gen_constant_list(pTHX_ OP* o);
STATIC void S_inplace_aassign(pTHX_ OP* o);
#define PERL_ARGS_ASSERT_INPLACE_AASSIGN \
assert(o)