summaryrefslogtreecommitdiff
path: root/scope.c
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2014-11-27 11:52:56 -0500
committerJarkko Hietaniemi <jhi@iki.fi>2014-11-27 11:54:02 -0500
commit51418c6ac55f33024e046e599878137a9e0a2e7d (patch)
tree653d1bec2ffc9ae7b9bc50c7b0701c72dc9f26e9 /scope.c
parentb943805ed26dc8b5a9dab8d9383c8ec13239c77a (diff)
downloadperl-51418c6ac55f33024e046e599878137a9e0a2e7d.tar.gz
Hoist switch-local variables.
Additionally, svp was shadowed. (clang -Wunreachable-code)
Diffstat (limited to 'scope.c')
-rw-r--r--scope.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/scope.c b/scope.c
index 8e13071a34..a1aa3f52a9 100644
--- a/scope.c
+++ b/scope.c
@@ -761,6 +761,9 @@ Perl_leave_scope(pTHX_ I32 base)
/* Localise the effects of the TAINT_NOT inside the loop. */
bool was = TAINT_get;
+ I32 i;
+ SV *sv;
+
ANY arg0, arg1, arg2;
/* these initialisations are logically unnecessary, but they shut up
@@ -983,11 +986,6 @@ Perl_leave_scope(pTHX_ I32 base)
Safefree(ARG0_PTR);
break;
- {
- SV **svp;
- I32 i;
- SV *sv;
-
case SAVEt_CLEARPADRANGE:
i = (I32)((uv >> SAVE_TIGHT_SHIFT) & OPpPADRANGE_COUNTMASK);
svp = &PL_curpad[uv >>
@@ -1107,7 +1105,6 @@ Perl_leave_scope(pTHX_ I32 base)
}
}
break;
- }
case SAVEt_DELETE:
(void)hv_delete(ARG0_HV, ARG2_PV, ARG1_I32, G_DISCARD);
SvREFCNT_dec(ARG0_HV);