summaryrefslogtreecommitdiff
path: root/pad.c
diff options
context:
space:
mode:
authorFather Chrysostomos <sprout@cpan.org>2012-08-13 22:56:05 -0700
committerFather Chrysostomos <sprout@cpan.org>2012-09-15 22:45:06 -0700
commit00cc874382d18406b0909f99025f70ca0df1996d (patch)
treee5917e2ff4afecfb6bb2d818a744b78171c549f3 /pad.c
parent0afba48f17ab3a5f576fdfaf4e4fc8671acde2bd (diff)
downloadperl-00cc874382d18406b0909f99025f70ca0df1996d.tar.gz
Preserve outside pointers of my subs with string eval
The CvHASEVAL flag lets cv_clone know that the clone needs to have its CvOUTSIDE pointer set, for the sake of string evals’ being able to look up variables. It was only being set on anonymous subs. It should be set for all clonable subs. It doesn’t actually hurt to set it on all types of subs, whether clonable or not, since it has no effect on non-clon- able subs.
Diffstat (limited to 'pad.c')
-rw-r--r--pad.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/pad.c b/pad.c
index 960d725d82..941f66382b 100644
--- a/pad.c
+++ b/pad.c
@@ -1716,8 +1716,8 @@ Perl_pad_tidy(pTHX_ padtidy_type type)
DEBUG_Xv(PerlIO_printf(Perl_debug_log,
"Pad clone on cv=0x%"UVxf"\n", PTR2UV(cv)));
CvCLONE_on(cv);
- CvHASEVAL_on(cv);
}
+ CvHASEVAL_on(cv);
}
}