summaryrefslogtreecommitdiff
path: root/pp.h
diff options
context:
space:
mode:
authorFather Chrysostomos <sprout@cpan.org>2012-01-09 12:46:01 -0800
committerFather Chrysostomos <sprout@cpan.org>2012-01-09 13:24:03 -0800
commit6b349a5c4c70a7c99eeaabacafc3ea993f2c7869 (patch)
tree6c873f46bdfbba9d2584bed44c217114ae36b54b /pp.h
parent10cca365fcca0349c1d46c3a7ac05f425585739f (diff)
downloadperl-6b349a5c4c70a7c99eeaabacafc3ea993f2c7869.tar.gz
[perl #44895] += warning on uninit magic var
The only uses of USE_LEFT in core now occur when SvGETMAGIC has already been called. So returning true for magical SVs is not neces- sary. In fact, it was never correct. Also, the code in do_vop (which handles bitwise operations on strings) to avoid an uninitialized warning had the same buggy SvGMAGICAL check. Now, the warning from $uninit += 1 is suppressed for all undefined vars, not just amagical ones. This causes 6 to-do tests in assignwarn.t to pass.
Diffstat (limited to 'pp.h')
-rw-r--r--pp.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/pp.h b/pp.h
index aaadd404c7..63b22340f9 100644
--- a/pp.h
+++ b/pp.h
@@ -345,7 +345,7 @@ Does not use C<TARG>. See also C<XPUSHu>, C<mPUSHu> and C<PUSHu>.
#define dPOPXiirl(X) IV right = POPi; IV left = CAT2(X,i)
#define USE_LEFT(sv) \
- (SvOK(sv) || SvGMAGICAL(sv) || !(PL_op->op_flags & OPf_STACKED))
+ (SvOK(sv) || !(PL_op->op_flags & OPf_STACKED))
#define dPOPXiirl_ul_nomg(X) \
IV right = (sp--, SvIV_nomg(TOPp1s)); \
SV *leftsv = CAT2(X,s); \