The branch that does POPSUB has an implicit CX_LEAVE_SCOPE; the
other branch didn't; do add one for consistency. It's fairly harmless,
as pp_sort shortly afterwards does a LEAVE() anyway.
Also add an assertion to POPBLOCK that the save stack has been popped;
this is how I discovered the sort issue in the first place.
PL_curcop = cx->blk_oldcop, \
PL_markstack_ptr = PL_markstack + cx->blk_oldmarksp, \
PL_scopestack_ix = cx->blk_oldscopesp, \
+ /* LEAVE_SCOPE() should have made this true. /(?{})/ cheats
+ * and leaves a CX entry lying around for repeated use, so
+ * skip for multicall */ \
+ assert(CxMULTICALL(cx) || \
+ PL_savestack_ix == cx->cx_u.cx_blk.blku_old_savestack_ix); \
PL_curpm = cx->blk_oldpm;
/* Continue a block elsewhere (NEXT and REDO). */
else
assert(CxTYPE(cx) == CXt_NULL);
/* mimic POPSUB */
+ CX_LEAVE_SCOPE(cx);
PL_tmps_floor = cx->cx_u.cx_blk.blku_old_tmpsfloor;
POPBLOCK(cx);