summaryrefslogtreecommitdiff
path: root/pp.h
diff options
context:
space:
mode:
authorKarl Williamson <khw@cpan.org>2020-08-29 11:00:28 -0600
committerKarl Williamson <khw@cpan.org>2020-11-11 09:18:12 -0700
commit8c2194213d30844320187ec6b2b6e37513000047 (patch)
tree210eae2b349214fbd4672cae22de60cde7243739 /pp.h
parent37dee3fa90c1d5bb5013371ba2d18b2371629684 (diff)
downloadperl-8c2194213d30844320187ec6b2b6e37513000047.tar.gz
Document TARG, dTARGET
Diffstat (limited to 'pp.h')
-rw-r--r--pp.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/pp.h b/pp.h
index cb50dbef03..da4e9da7d5 100644
--- a/pp.h
+++ b/pp.h
@@ -53,6 +53,16 @@ Refetch the stack pointer. Used after a callback. See L<perlcall>.
#undef SP /* Solaris 2.7 i386 has this in /usr/include/sys/reg.h */
#define SP sp
#define MARK mark
+
+/*
+=for apidoc Amns||TARG
+
+C<TARG> is short for "target". It is an entry in the pad that an OPs
+C<op_targ> refers to. It is scratchpad space, often used as a return
+value for the OP, but some use it for other purposes.
+
+=cut
+*/
#define TARG targ
#define PUSHMARK(p) \
@@ -91,6 +101,13 @@ Refetch the stack pointer. Used after a callback. See L<perlcall>.
#define dTARGETSTACKED SV * GETTARGETSTACKED
#define GETTARGET targ = PAD_SV(PL_op->op_targ)
+
+/*
+=for apidoc Amns||dTARGET
+Declare that this function uses C<TARG>
+
+=cut
+*/
#define dTARGET SV * GETTARGET
#define GETATARGET targ = (PL_op->op_flags & OPf_STACKED ? sp[-1] : PAD_SV(PL_op->op_targ))