/* op.h
*
- * Copyright (c) 1991-2000, Larry Wall
+ * Copyright (c) 1991-2001, Larry Wall
*
* You may distribute under the terms of either the GNU General Public
* License or the Artistic License, as specified in the README file.
/*
=for apidoc Amn|U32|GIMME_V
The XSUB-writer's equivalent to Perl's C<wantarray>. Returns C<G_VOID>,
-C<G_SCALAR> or C<G_ARRAY> for void, scalar or array context,
+C<G_SCALAR> or C<G_ARRAY> for void, scalar or list context,
respectively.
=for apidoc Amn|U32|GIMME
/* On OP_EXISTS, treat av as av, not avhv. */
/* On OP_(ENTER|LEAVE)EVAL, don't clear $@ */
/* On OP_ENTERITER, loop var is per-thread */
- /* On pushre, re is /\s+/ imp. by split " " */
+ /* On pushre, re is /\s+/ imp. by split " " */
+ /* On regcomp, "use re 'eval'" was in scope */
/* old names; don't use in new code, but don't break them, either */
#define OPf_LIST OPf_WANT_LIST
/* Private for OP_TRANS */
#define OPpTRANS_FROM_UTF 1
#define OPpTRANS_TO_UTF 2
-#define OPpTRANS_IDENTICAL 4
- /* When CU or UC, means straight latin-1 to utf-8 or vice versa */
- /* Otherwise, IDENTICAL means the right side is the same as the left */
+#define OPpTRANS_IDENTICAL 4 /* right side is same as left */
#define OPpTRANS_SQUASH 8
#define OPpTRANS_DELETE 16
#define OPpTRANS_COMPLEMENT 32
/* Private for OP_REPEAT */
#define OPpREPEAT_DOLIST 64 /* List replication. */
-/* Private for OP_LEAVELOOP */
-#define OPpLOOP_CONTINUE 64 /* a continue block is present */
-
/* Private for OP_RV2?V, OP_?ELEM */
#define OPpDEREF (32|64) /* Want ref to something: */
#define OPpDEREF_AV 32 /* Want ref to AV. */
/* OP_?ELEM only */
#define OPpLVAL_DEFER 16 /* Defer creation of array/hash elem */
/* OP_RV2?V, OP_GVSV only */
-#define OPpOUR_INTRO 16 /* Defer creation of array/hash elem */
+#define OPpOUR_INTRO 16 /* Variable was in an our() */
+ /* OP_RV2[AH]V, OP_PAD[AH]V, OP_[AH]ELEM */
+#define OPpMAYBE_LVSUB 8 /* We might be an lvalue to return */
/* for OP_RV2?V, lower bits carry hints (currently only HINT_STRICT_REFS) */
/* Private for OPs with TARGLEX */
BASEOP
OP * op_first;
OP * op_last;
- U32 op_children;
};
struct pmop {
BASEOP
OP * op_first;
OP * op_last;
- U32 op_children;
OP * op_pmreplroot;
OP * op_pmreplstart;
PMOP * op_pmnext; /* list of all scanpats */
#define PMdf_USED 0x01 /* pm has been used once already */
#define PMdf_TAINTED 0x02 /* pm compiled from tainted pattern */
#define PMdf_UTF8 0x04 /* pm compiled from utf8 data */
+#define PMdf_DYN_UTF8 0x08
+
+#define PMdf_CMP_UTF8 (PMdf_UTF8|PMdf_DYN_UTF8)
#define PMf_RETAINT 0x0001 /* taint $1 etc. if target tainted */
#define PMf_ONCE 0x0002 /* use pattern only once per reset */
BASEOP
OP * op_first;
OP * op_last;
- U32 op_children;
OP * op_redoop;
OP * op_nextop;
OP * op_lastop;