diff options
author | Father Chrysostomos <sprout@cpan.org> | 2012-07-13 18:10:38 -0700 |
---|---|---|
committer | Father Chrysostomos <sprout@cpan.org> | 2012-07-13 18:10:38 -0700 |
commit | dd9a6ccfcb1b5e26680c14c1663ea9fac4480690 (patch) | |
tree | 71ed0d182d35ceed4cb2007b0366b3d867fd08bf /regen/opcodes | |
parent | c75cfcf022bbc2d851c911d5a33a70983d4ede48 (diff) | |
download | perl-dd9a6ccfcb1b5e26680c14c1663ea9fac4480690.tar.gz |
[perl #113470] Constant folding for pack
This takes the pessimistic approach of skipping it for any first argu-
ment that is not a plain non-magical PV, just in case there is a 'p'
or 'P' in the stringified form.
Otherwise it scans the PV for 'p' or 'P' and skips the folding if either
is present.
Then it falls through to the usual op-filtering logic.
I nearly made ‘pack;’ crash, so I added a test to bproto.t.
Diffstat (limited to 'regen/opcodes')
-rw-r--r-- | regen/opcodes | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/regen/opcodes b/regen/opcodes index 8666d8c924..da2212a142 100644 --- a/regen/opcodes +++ b/regen/opcodes @@ -237,7 +237,7 @@ boolkeys boolkeys ck_fun % H # Explosives and implosives. unpack unpack ck_fun u@ S S? -pack pack ck_fun mst@ S L +pack pack ck_fun fmst@ S L split split ck_split t@ S S S join join or string ck_join mst@ S L |