summaryrefslogtreecommitdiff
path: root/scope.c
diff options
context:
space:
mode:
Diffstat (limited to 'scope.c')
-rw-r--r--scope.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/scope.c b/scope.c
index 11c81bde94..31a3ebc44b 100644
--- a/scope.c
+++ b/scope.c
@@ -755,6 +755,9 @@ Perl_leave_scope(pTHX_ I32 base)
gv = (GV*)SSPOPPTR;
if (GvAV(gv)) {
AV * const goner = GvAV(gv);
+ /* FIXME - this is a temporary hack until we work out what
+ the correct behaviour for magic should be. */
+ sv_unmagic((SV*)goner, PERL_MAGIC_arylen_p);
SvMAGIC_set(av, SvMAGIC(goner));
SvFLAGS((SV*)av) |= SvMAGICAL(goner);
SvMAGICAL_off(goner);