summaryrefslogtreecommitdiff
path: root/op.c
diff options
context:
space:
mode:
authorFather Chrysostomos <sprout@cpan.org>2014-11-10 18:57:45 -0800
committerFather Chrysostomos <sprout@cpan.org>2014-11-10 18:57:45 -0800
commitd6ca65d8388b907ff537a8597ee026ad42d5c00f (patch)
treeec25f86883a30505c16195083f55d8c953d9e650 /op.c
parent2c217c4598fa36f236d5085b4d73b7282b80beb1 (diff)
downloadperl-d6ca65d8388b907ff537a8597ee026ad42d5c00f.tar.gz
op.c:ck_sassign: Don’t check the pad name for state
The padsv op will already have its state flag set by this point, so we can merge two flag checks into one, resulting in smaller machine code.
Diffstat (limited to 'op.c')
-rw-r--r--op.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/op.c b/op.c
index 604265077e..cc35794e28 100644
--- a/op.c
+++ b/op.c
@@ -10179,8 +10179,8 @@ Perl_ck_sassign(pTHX_ OP *o)
(kkid = cLISTOPx(kkid)->op_last)->op_type == OP_PADSV
)
)
- && (kkid->op_private & OPpLVAL_INTRO)
- && SvPAD_STATE(PAD_COMPNAME_SV(kkid->op_targ))) {
+ && (kkid->op_private & (OPpLVAL_INTRO|OPpPAD_STATE))
+ == (OPpLVAL_INTRO|OPpPAD_STATE)) {
const PADOFFSET target = kkid->op_targ;
OP *const other = newOP(OP_PADSV,
kkid->op_flags