summaryrefslogtreecommitdiff
path: root/mg.c
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2010-02-20 17:19:53 +0000
committerNicholas Clark <nick@ccl4.org>2010-05-03 07:50:33 +0100
commit1be36ce045f4d933ecfaa47bd82b0c6eeb0384c2 (patch)
tree7251d7a6bb1da78adbbc6d914108494784a29e90 /mg.c
parentf38f76ae8646ea71778a38f2a33a5c8e091d006f (diff)
downloadperl-1be36ce045f4d933ecfaa47bd82b0c6eeb0384c2.tar.gz
For SAVEt_ALLOC, store the number of save stack entries used with the type.
Diffstat (limited to 'mg.c')
-rw-r--r--mg.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/mg.c b/mg.c
index 59ead344d0..3c5702669f 100644
--- a/mg.c
+++ b/mg.c
@@ -3071,14 +3071,12 @@ S_restore_magic(pTHX_ const void *p)
*/
if (PL_savestack_ix == mgs->mgs_ss_ix)
{
- UV type = SSPOPUV;
- I32 popval;
- assert(type == SAVEt_DESTRUCTOR_X);
+ UV popval = SSPOPUV;
+ assert(popval == SAVEt_DESTRUCTOR_X);
PL_savestack_ix -= 2;
- type = SSPOPUV;
- assert(type == SAVEt_ALLOC);
- popval = SSPOPINT;
- PL_savestack_ix -= popval;
+ popval = SSPOPUV;
+ assert((popval & SAVE_MASK) == SAVEt_ALLOC);
+ PL_savestack_ix -= popval >> SAVE_TIGHT_SHIFT;
}
}