X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=toke.c;h=13582da4b055dd6c6063b07d75e66b983e5afbe0;hb=b21a80ce2a669073adfd175b505267b94bc65e88;hp=c5f9c8fe9f0fa4b0bfeb5637ed359c0f7c4abae6;hpb=5f66b61cbe1f2ea985f00c0d9a66153e7a3b6ee1;p=p5sagit%2Fp5-mst-13.2.git diff --git a/toke.c b/toke.c index c5f9c8f..13582da 100644 --- a/toke.c +++ b/toke.c @@ -820,7 +820,7 @@ S_skipspace(pTHX_ register char *s) PerlIO_clearerr(PL_rsfp); else (void)PerlIO_close(PL_rsfp); - PL_rsfp = Nullfp; + PL_rsfp = NULL; return s; } @@ -1215,7 +1215,7 @@ S_sublex_start(pTHX) if (SvTYPE(sv) == SVt_PVIV) { /* Overloaded constants, nothing fancy: Convert to SVt_PV: */ STRLEN len; - const char *p = SvPV_const(sv, len); + const char * const p = SvPV_const(sv, len); SV * const nsv = newSVpvn(p, len); if (SvUTF8(sv)) SvUTF8_on(nsv); @@ -2781,7 +2781,7 @@ Perl_yylex(pTHX) PerlIO_clearerr(PL_rsfp); else (void)PerlIO_close(PL_rsfp); - PL_rsfp = Nullfp; + PL_rsfp = NULL; PL_doextract = FALSE; } if (!PL_in_eval && (PL_minus_n || PL_minus_p)) { @@ -3319,7 +3319,7 @@ Perl_yylex(pTHX) #ifdef USE_ITHREADS GvUNIQUE_on(cGVOPx_gv(yylval.opval)); #else - ; /* skip to avoid loading attributes.pm */ + /*EMPTY*/; /* skip to avoid loading attributes.pm */ #endif else Perl_croak(aTHX_ "The 'unique' attribute may only be applied to 'our' variables"); @@ -4443,7 +4443,7 @@ Perl_yylex(pTHX) if ((sv = gv_const_sv(gv))) { its_constant: SvREFCNT_dec(((SVOP*)yylval.opval)->op_sv); - ((SVOP*)yylval.opval)->op_sv = SvREFCNT_inc(sv); + ((SVOP*)yylval.opval)->op_sv = SvREFCNT_inc_simple(sv); yylval.opval->op_private = 0; TOKEN(WORD); } @@ -4610,7 +4610,7 @@ Perl_yylex(pTHX) } } #endif - PL_rsfp = Nullfp; + PL_rsfp = NULL; } goto fake_eof; } @@ -5751,7 +5751,7 @@ S_pending_ident(pTHX) tmp = pad_findmy(PL_tokenbuf); if (tmp != NOT_IN_PAD) { /* might be an "our" variable" */ - if (PAD_COMPNAME_FLAGS(tmp) & SVpad_OUR) { + if (PAD_COMPNAME_FLAGS_isOUR(tmp)) { /* build ops for a bareword */ HV * const stash = PAD_COMPNAME_OURSTASH(tmp); HEK * const stashname = HvNAME_HEK(stash); @@ -9329,11 +9329,11 @@ S_new_constant(pTHX_ const char *s, STRLEN len, const char *key, SV *sv, SV *pv, sv_catpvs(ERRSV, "Propagated"); yyerror(SvPV_nolen_const(ERRSV)); /* Duplicates the message inside eval */ (void)POPs; - res = SvREFCNT_inc(sv); + res = SvREFCNT_inc_simple(sv); } else { res = POPs; - (void)SvREFCNT_inc(res); + SvREFCNT_inc_simple_void(res); } PUTBACK ; @@ -9552,6 +9552,7 @@ S_scan_ident(pTHX_ register char *s, register const char *send, char *dest, STRL void Perl_pmflag(pTHX_ U32* pmfl, int ch) { + PERL_UNUSED_CONTEXT; if (ch == 'i') *pmfl |= PMf_FOLD; else if (ch == 'g') @@ -10037,7 +10038,7 @@ S_scan_inputsymbol(pTHX_ char *start) add symbol table ops */ if ((tmp = pad_findmy(d)) != NOT_IN_PAD) { - if (PAD_COMPNAME_FLAGS(tmp) & SVpad_OUR) { + if (PAD_COMPNAME_FLAGS_isOUR(tmp)) { HV * const stash = PAD_COMPNAME_OURSTASH(tmp); HEK * const stashname = HvNAME_HEK(stash); SV * const sym = sv_2mortal(newSVhek(stashname)); @@ -10923,7 +10924,9 @@ S_set_csh(pTHX) if (!PL_cshlen) PL_cshlen = strlen(PL_cshname); #else - PERL_UNUSED_ARG(my_perl); +#if defined(USE_ITHREADS) + PERL_UNUSED_CONTEXT; +#endif #endif } @@ -10947,7 +10950,7 @@ Perl_start_subparse(pTHX_ I32 is_format, U32 flags) PL_subline = CopLINE(PL_curcop); CvPADLIST(PL_compcv) = pad_new(padnew_SAVE|padnew_SAVESUB); - CvOUTSIDE(PL_compcv) = (CV*)SvREFCNT_inc(outsidecv); + CvOUTSIDE(PL_compcv) = (CV*)SvREFCNT_inc_simple(outsidecv); CvOUTSIDE_SEQ(PL_compcv) = PL_cop_seqmax; return oldsavestack_ix;