# if defined(PERL_IN_PAD_C)
#define pad_alloc_name(a,b,c,d) S_pad_alloc_name(aTHX_ a,b,c,d)
#define pad_check_dup(a,b,c) S_pad_check_dup(aTHX_ a,b,c)
-#define pad_findlex(a,b,c,d,e,f,g,h) S_pad_findlex(aTHX_ a,b,c,d,e,f,g,h)
+#define pad_findlex(a,b,c,d,e,f,g,h,i) S_pad_findlex(aTHX_ a,b,c,d,e,f,g,h,i)
#define pad_reset() S_pad_reset(aTHX)
# endif
# if defined(PERL_IN_PERL_C)
Perl_croak(aTHX_ "panic: pad_findmy_pvn illegal flag bits 0x%" UVxf,
(UV)flags);
- offset = pad_findlex(namepv, namelen, PL_compcv, PL_cop_seqmax, 1,
- NULL, &out_sv, &out_flags);
+ offset = pad_findlex(namepv, namelen, flags,
+ PL_compcv, PL_cop_seqmax, 1, NULL, &out_sv, &out_flags);
if ((PADOFFSET)offset != NOT_IN_PAD)
return offset;
dVAR;
SV *out_sv;
int out_flags;
- return pad_findlex("$_", 2, find_runcv(NULL), PL_curcop->cop_seq, 1,
+ return pad_findlex("$_", 2, 0, find_runcv(NULL), PL_curcop->cop_seq, 1,
NULL, &out_sv, &out_flags);
}
int flags;
PADOFFSET po;
- po = pad_findlex("$_", 2, find_runcv(NULL), PL_curcop->cop_seq, 1,
+ po = pad_findlex("$_", 2, 0, find_runcv(NULL), PL_curcop->cop_seq, 1,
NULL, &namesv, &flags);
if (po == NOT_IN_PAD || SvPAD_OUR(namesv))
}
/*
-=for apidoc m|PADOFFSET|pad_findlex|const char *namepv|STRLEN namelen|const CV* cv|U32 seq|int warn|SV** out_capture|SV** out_name_sv|int *out_flags
+=for apidoc m|PADOFFSET|pad_findlex|const char *namepv|STRLEN namelen|U32 flags|const CV* cv|U32 seq|int warn|SV** out_capture|SV** out_name_sv|int *out_flags
Find a named lexical anywhere in a chain of nested pads. Add fake entries
in the inner pads if it's found in an outer one.
STATIC PADOFFSET
-S_pad_findlex(pTHX_ const char *namepv, STRLEN namelen, const CV* cv, U32 seq,
+S_pad_findlex(pTHX_ const char *namepv, STRLEN namelen, U32 flags, const CV* cv, U32 seq,
int warn, SV** out_capture, SV** out_name_sv, int *out_flags)
{
dVAR;
"Pad findlex cv=0x%"UVxf" chasing lex in outer pad\n",
PTR2UV(cv)));
n = *out_name_sv;
- (void) pad_findlex(namepv, namelen, CvOUTSIDE(cv),
+ (void) pad_findlex(namepv, namelen, flags, CvOUTSIDE(cv),
CvOUTSIDE_SEQ(cv),
newwarn, out_capture, out_name_sv, out_flags);
*out_name_sv = n;
new_capturep = out_capture ? out_capture :
CvLATE(cv) ? NULL : &new_capture;
- offset = pad_findlex(namepv, namelen, CvOUTSIDE(cv), CvOUTSIDE_SEQ(cv), 1,
+ offset = pad_findlex(namepv, namelen, flags, CvOUTSIDE(cv), CvOUTSIDE_SEQ(cv), 1,
new_capturep, out_name_sv, out_flags);
if ((PADOFFSET)offset == NOT_IN_PAD)
return NOT_IN_PAD;
#define PERL_ARGS_ASSERT_PAD_CHECK_DUP \
assert(name)
-STATIC PADOFFSET S_pad_findlex(pTHX_ const char *namepv, STRLEN namelen, const CV* cv, U32 seq, int warn, SV** out_capture, SV** out_name_sv, int *out_flags)
+STATIC PADOFFSET S_pad_findlex(pTHX_ const char *namepv, STRLEN namelen, U32 flags, const CV* cv, U32 seq, int warn, SV** out_capture, SV** out_name_sv, int *out_flags)
__attribute__nonnull__(pTHX_1)
- __attribute__nonnull__(pTHX_3)
- __attribute__nonnull__(pTHX_7)
- __attribute__nonnull__(pTHX_8);
+ __attribute__nonnull__(pTHX_4)
+ __attribute__nonnull__(pTHX_8)
+ __attribute__nonnull__(pTHX_9);
#define PERL_ARGS_ASSERT_PAD_FINDLEX \
assert(namepv); assert(cv); assert(out_name_sv); assert(out_flags)