summaryrefslogtreecommitdiff
path: root/op.h
diff options
context:
space:
mode:
authorDavid Mitchell <davem@iabyn.com>2012-10-30 15:10:06 +0000
committerDavid Mitchell <davem@iabyn.com>2012-11-10 13:39:32 +0000
commitd5524600caf9e8c470e731c4f5a924868154645a (patch)
treeabed2ab4c1c8d698b7fe2c5efdeaec392b680e57 /op.h
parent528ad060d8dbad9e971c22550cece80330a23dd3 (diff)
downloadperl-d5524600caf9e8c470e731c4f5a924868154645a.tar.gz
padrange: handle @_ directly
In a construct like my ($x,$y) = @_ the pushmark/padsv/padsv is already optimised into a single padrange op. This commit makes the OPf_SPECIAL flag on the padrange op indicate that in addition, @_ should be pushed onto the stack, skipping an additional pushmark/gv[*_]/rv2sv combination. So in total (including the earlier padrange work), the above construct goes from being 3 <0> pushmark s 4 <$> gv(*_) s 5 <1> rv2av[t3] lK/1 6 <0> pushmark sRM*/128 7 <0> padsv[$x:1,2] lRM*/LVINTRO 8 <0> padsv[$y:1,2] lRM*/LVINTRO 9 <2> aassign[t4] vKS to 3 <0> padrange[$x:1,2; $y:1,2] l*/LVINTRO,2 ->4 4 <2> aassign[t4] vKS
Diffstat (limited to 'op.h')
-rw-r--r--op.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/op.h b/op.h
index 07ad34c9e0..210521e700 100644
--- a/op.h
+++ b/op.h
@@ -140,6 +140,7 @@ Deprecated. Use C<GIMME_V> instead.
- Before ck_glob, called as CORE::glob
- After ck_glob, use Perl glob function
*/
+ /* On OP_PADRANGE, push @_ */
/* old names; don't use in new code, but don't break them, either */
#define OPf_LIST OPf_WANT_LIST