diff options
author | David Mitchell <davem@iabyn.com> | 2011-10-07 15:38:56 +0100 |
---|---|---|
committer | David Mitchell <davem@iabyn.com> | 2011-10-07 20:07:48 +0100 |
commit | 9a214eecd07ed44274740f81d8dce0e526badf80 (patch) | |
tree | 1e33a4db9f23d13f72f267978a83a39188677a11 /sv.c | |
parent | d0c0e7dd0ccf3d5c2f658529d3ee578a0bcb116e (diff) | |
download | perl-9a214eecd07ed44274740f81d8dce0e526badf80.tar.gz |
make SVs_PADTMP and SVs_PADSTALE share a bit
SVs_PADSTALE is only meaningful with SVs_PADMY, while
SVs_PADTMP is only meaningful with !SVs_PADMY,
so let them share the same flag bit.
Note that this doesn't yet free a bit in SvFLAGS, as the two
bits are also used for SVpad_STATE, SVpad_TYPED.
(This is is follow-on to 62bb6514085e5eddc42b4fdaf3713ccdb7f1da85.)
Diffstat (limited to 'sv.c')
-rw-r--r-- | sv.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -2228,7 +2228,7 @@ S_sv_2iuv_common(pTHX_ SV *const sv) if (isGV_with_GP(sv)) return glob_2number(MUTABLE_GV(sv)); - if (!(SvFLAGS(sv) & SVs_PADTMP)) { + if (!SvPADTMP(sv)) { if (!PL_localizing && ckWARN(WARN_UNINITIALIZED)) report_uninit(sv); } @@ -2613,7 +2613,7 @@ Perl_sv_2nv_flags(pTHX_ register SV *const sv, const I32 flags) return 0.0; } - if (!PL_localizing && !(SvFLAGS(sv) & SVs_PADTMP) && ckWARN(WARN_UNINITIALIZED)) + if (!PL_localizing && !SvPADTMP(sv) && ckWARN(WARN_UNINITIALIZED)) report_uninit(sv); assert (SvTYPE(sv) >= SVt_NV); /* Typically the caller expects that sv_any is not NULL now. */ @@ -2975,7 +2975,7 @@ Perl_sv_2pv_flags(pTHX_ register SV *const sv, STRLEN *const lp, const I32 flags *lp = 0; if (flags & SV_UNDEF_RETURNS_NULL) return NULL; - if (!PL_localizing && !(SvFLAGS(sv) & SVs_PADTMP) && ckWARN(WARN_UNINITIALIZED)) + if (!PL_localizing && !SvPADTMP(sv) && ckWARN(WARN_UNINITIALIZED)) report_uninit(sv); if (SvTYPE(sv) < SVt_PV) /* Typically the caller expects that sv_any is not NULL now. */ |