diff options
author | Father Chrysostomos <sprout@cpan.org> | 2014-09-11 17:59:11 -0700 |
---|---|---|
committer | Father Chrysostomos <sprout@cpan.org> | 2014-09-15 06:19:34 -0700 |
commit | 9c98a81fd30898ed03895d1368f4f9f2761b69da (patch) | |
tree | dfe35ce9e495fa57b119318981480df9b365639a /op.h | |
parent | 4bc93fb921ea9f73602571ed903edcead3956e66 (diff) | |
download | perl-9c98a81fd30898ed03895d1368f4f9f2761b69da.tar.gz |
op.c:ck_subr: reify GVs based on call checker
Instead of faking up a GV to pass to the call checker if we have a
lexical sub, just get the GV from CvGV (since that will reify the GV,
even for lexical subs), unless the call checker has not specifically
requested GVs.
For now, we assume the default call checker cannot handle non-GV sub
names, as indeed it cannot. An imminent commit will rectify that.
The code in scope.c was getting the name hek from the proto CV (stowed
in magic on the pad name) if the CV in the pad had lost it. Now, the
proto CV can lose it at compile time via CvGV, so that does not work
anymore. Instead, just get it from the GV.
Diffstat (limited to 'op.h')
-rw-r--r-- | op.h | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -693,7 +693,10 @@ preprocessing token; the type of I<arg> depends on I<which>. #define RV2CVOPCV_MARK_EARLY 0x00000001 #define RV2CVOPCV_RETURN_NAME_GV 0x00000002 #define RV2CVOPCV_RETURN_STUB 0x00000004 -#define RV2CVOPCV_FLAG_MASK 0x00000007 /* all of the above */ +#ifdef PERL_CORE /* behaviour of this flag is subject to change: */ +# define RV2CVOPCV_MAYBE_NAME_GV 0x00000008 +#endif +#define RV2CVOPCV_FLAG_MASK 0x0000000f /* all of the above */ #define op_lvalue(op,t) Perl_op_lvalue_flags(aTHX_ op,t,0) |