summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cop.h1
-rw-r--r--pp_ctl.c6
2 files changed, 7 insertions, 0 deletions
diff --git a/cop.h b/cop.h
index 05ed67f093..98674158b9 100644
--- a/cop.h
+++ b/cop.h
@@ -1251,6 +1251,7 @@ See L<perlcall/LIGHTWEIGHT CALLBACKS>.
CvDEPTH(multicall_cv) = cx->blk_sub.olddepth; \
LEAVESUB(multicall_cv); \
POPBLOCK(cx,PL_curpm); \
+ /* includes partial unrolled POPSUB(): */ \
LEAVE_SCOPE(PL_scopestack[cx->blk_oldscopesp-1]); \
PL_comppad = cx->blk_sub.prevcomppad; \
PL_curpad = LIKELY(PL_comppad) ? AvARRAY(PL_comppad) : NULL; \
diff --git a/pp_ctl.c b/pp_ctl.c
index 66a78c2870..455b7cf8b1 100644
--- a/pp_ctl.c
+++ b/pp_ctl.c
@@ -2726,6 +2726,9 @@ PP(pp_goto)
SvREFCNT_dec(cv);
DIE(aTHX_ "Can't goto subroutine from a sort sub (or similar callback)");
}
+
+ /* partial unrolled POPSUB(): */
+
if (CxTYPE(cx) == CXt_SUB && CxHASARGS(cx)) {
AV* av = cx->blk_sub.argarray;
@@ -2823,6 +2826,9 @@ PP(pp_goto)
}
else {
PADLIST * const padlist = CvPADLIST(cv);
+
+ /* partial unrolled PUSHSUB(): */
+
cx->blk_sub.cv = cv;
cx->blk_sub.olddepth = CvDEPTH(cv);