summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pp.h5
-rw-r--r--pp_hot.c2
-rw-r--r--pp_sys.c2
3 files changed, 4 insertions, 5 deletions
diff --git a/pp.h b/pp.h
index ca59246b2d..377d489f26 100644
--- a/pp.h
+++ b/pp.h
@@ -420,18 +420,17 @@ Does not use C<TARG>. See also C<XPUSHu>, C<mPUSHu> and C<PUSHu>.
/* No longer used in core. Use AMG_CALLunary instead */
#define AMG_CALLun(sv,meth) AMG_CALLunary(sv, CAT2(meth,_amg))
-#define tryAMAGICunTARGETlist(meth, shift, jump) \
+#define tryAMAGICunTARGETlist(meth, jump) \
STMT_START { \
dSP; \
SV *tmpsv; \
- SV *arg= sp[shift]; \
+ SV *arg= *sp; \
int gimme = GIMME_V; \
if (SvAMAGIC(arg) && \
(tmpsv = amagic_call(arg, &PL_sv_undef, meth, \
AMGf_want_list | AMGf_noright \
|AMGf_unary))) { \
SPAGAIN; \
- sp += shift; \
if (gimme == G_VOID) { \
(void)POPs; /* XXX ??? */ \
} \
diff --git a/pp_hot.c b/pp_hot.c
index 59981102d2..feba395014 100644
--- a/pp_hot.c
+++ b/pp_hot.c
@@ -425,7 +425,7 @@ PP(pp_readline)
dSP;
if (TOPs) {
SvGETMAGIC(TOPs);
- tryAMAGICunTARGETlist(iter_amg, 0, 0);
+ tryAMAGICunTARGETlist(iter_amg, 0);
PL_last_in_gv = MUTABLE_GV(*PL_stack_sp--);
}
else PL_last_in_gv = PL_argvgv, PL_stack_sp--;
diff --git a/pp_sys.c b/pp_sys.c
index ec77763723..8bf9fa7cf1 100644
--- a/pp_sys.c
+++ b/pp_sys.c
@@ -367,7 +367,7 @@ PP(pp_glob)
* is called once and only once */
if (SvGMAGICAL(TOPs)) TOPs = sv_2mortal(newSVsv(TOPs));
- tryAMAGICunTARGETlist(iter_amg, 0, (PL_op->op_flags & OPf_SPECIAL));
+ tryAMAGICunTARGETlist(iter_amg, (PL_op->op_flags & OPf_SPECIAL));
if (PL_op->op_flags & OPf_SPECIAL) {
/* call Perl-level glob function instead. Stack args are: