X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=pp_ctl.c;h=0a01c11e7cd620136e19f13f08e276a7782640a7;hb=3c10ad8e31f7d77e71c048b1746912f41cb540f0;hp=6eab4da34e9ccb903681b6fd7a8de337a2807749;hpb=a61fe43df197fcc70e6f310c06ee17d52b606c45;p=p5sagit%2Fp5-mst-13.2.git diff --git a/pp_ctl.c b/pp_ctl.c index 6eab4da..0a01c11 100644 --- a/pp_ctl.c +++ b/pp_ctl.c @@ -1,6 +1,6 @@ /* pp_ctl.c * - * Copyright (c) 1991-1994, Larry Wall + * Copyright (c) 1991-1997, Larry Wall * * You may distribute under the terms of either the GNU General Public * License or the Artistic License, as specified in the README file. @@ -798,11 +798,11 @@ char *label; case CXt_LOOP: if (!cx->blk_loop.label || strNE(label, cx->blk_loop.label) ) { - DEBUG_l(deb("(Skipping label #%d %s)\n", - i, cx->blk_loop.label)); + DEBUG_l(deb("(Skipping label #%ld %s)\n", + (long)i, cx->blk_loop.label)); continue; } - DEBUG_l( deb("(Found label #%d %s)\n", i, label)); + DEBUG_l( deb("(Found label #%ld %s)\n", (long)i, label)); return i; } } @@ -837,7 +837,7 @@ I32 startingblock; continue; case CXt_EVAL: case CXt_SUB: - DEBUG_l( deb("(Found sub #%d)\n", i)); + DEBUG_l( deb("(Found sub #%ld)\n", (long)i)); return i; } } @@ -856,7 +856,7 @@ I32 startingblock; default: continue; case CXt_EVAL: - DEBUG_l( deb("(Found eval #%d)\n", i)); + DEBUG_l( deb("(Found eval #%ld)\n", (long)i)); return i; } } @@ -889,7 +889,7 @@ I32 startingblock; warn("Exiting pseudo-block via %s", op_name[op->op_type]); return -1; case CXt_LOOP: - DEBUG_l( deb("(Found loop #%d)\n", i)); + DEBUG_l( deb("(Found loop #%ld)\n", (long)i)); return i; } } @@ -1127,8 +1127,8 @@ sortcv(a, b) const void *a; const void *b; { - SV **str1 = (SV **) a; - SV **str2 = (SV **) b; + SV * const *str1 = (SV * const *)a; + SV * const *str2 = (SV * const *)b; I32 oldsaveix = savestack_ix; I32 oldscopeix = scopestack_ix; I32 result; @@ -1154,7 +1154,7 @@ sortcmp(a, b) const void *a; const void *b; { - return sv_cmp(*(SV **)a, *(SV **)b); + return sv_cmp(*(SV * const *)a, *(SV * const *)b); } static int @@ -1162,7 +1162,7 @@ sortcmp_locale(a, b) const void *a; const void *b; { - return sv_cmp_locale(*(SV **)a, *(SV **)b); + return sv_cmp_locale(*(SV * const *)a, *(SV * const *)b); } PP(pp_reset) @@ -1946,10 +1946,10 @@ OP *o; { int ret; int oldrunlevel = runlevel; + OP *oldop = op; Sigjmp_buf oldtop; op = o; - runlevel--; /* pretense */ Copy(top_env, oldtop, 1, Sigjmp_buf); #ifdef DEBUGGING assert(mustcatch == TRUE); @@ -1960,6 +1960,7 @@ OP *o; Copy(oldtop, top_env, 1, Sigjmp_buf); runlevel = oldrunlevel; mustcatch = TRUE; + op = oldop; Siglongjmp(top_env, ret); /* NOTREACHED */ case 3: @@ -1967,6 +1968,7 @@ OP *o; PerlIO_printf(PerlIO_stderr(), "panic: restartop\n"); break; } + mustcatch = FALSE; op = restartop; restartop = 0; /* FALL THROUGH */ @@ -1977,6 +1979,7 @@ OP *o; Copy(oldtop, top_env, 1, Sigjmp_buf); runlevel = oldrunlevel; mustcatch = TRUE; + op = oldop; return Nullop; }