Don’t use PMf_ONCE flag for split-to-array
Currently the PMf_ONCE flag has two purposes. It is used to indicate
that m?? must match only once. That’s what distinguishes m?? and m//
internally. The other use indicates that @x = split... modifies the
array in place.
Whenever the split op is modified to point straight to the array, the
PMf_ONCE flag is set. pp_split checks both whether there is an array
attached to the op (via a GV in the pad under threads, or a pointer
from the op to the GV under non-threaded builds) and whether the
flag is set.
This makes the flag redundant in the split case.
Removing its use here not only simplifies the code and removes redun-
dant bit-fiddling, but also makes this comment in toke.c, added by
ad639bfb6, come true:
/* This is the only point in the code that sets PMf_ONCE: */
(That was actually harmless, as it doesn’t hurt to have a stash refer-
ring to pmops that don’t use the PMf_USED flag, and the PMf_ONCE flag
is set for split way after that code is run. It is also unnecessary
for split, as that bookkeeping code in toke.c only applies to the m??
use of PMf_ONCE.)
This commit also removes a gimme != G_ARRAY check that thas been
redundant since
a6d8037e26a.