This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
[MERGE] refactor pp_iter
[perl5.git] / op.h
diff --git a/op.h b/op.h
index 07ad34c..935e126 100644 (file)
--- 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
@@ -569,7 +570,7 @@ struct loop {
 #  define      cGVOPx_gv(o)    ((GV*)PAD_SVl(cPADOPx(o)->op_padix))
 #  define      IS_PADGV(v)     (v && SvTYPE(v) == SVt_PVGV && isGV_with_GP(v) \
                                 && GvIN_PAD(v))
-#  define      IS_PADCONST(v)  (v && SvREADONLY(v))
+#  define      IS_PADCONST(v)  (v && (SvREADONLY(v) || SvIsCOW(v)))
 #  define      cSVOPx_sv(v)    (cSVOPx(v)->op_sv \
                                 ? cSVOPx(v)->op_sv : PAD_SVl((v)->op_targ))
 #  define      cSVOPx_svp(v)   (cSVOPx(v)->op_sv \