Edit File by line
/home/barbar84/www/wp-conte.../plugins/sujqvwi/AnonR/smanonr..../lib64/perl5/CORE
File: op.h
/* op.h
[0] Fix | Delete
*
[1] Fix | Delete
* Copyright (C) 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
[2] Fix | Delete
* 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by Larry Wall and others
[3] Fix | Delete
*
[4] Fix | Delete
* You may distribute under the terms of either the GNU General Public
[5] Fix | Delete
* License or the Artistic License, as specified in the README file.
[6] Fix | Delete
*
[7] Fix | Delete
*/
[8] Fix | Delete
[9] Fix | Delete
/*
[10] Fix | Delete
* The fields of BASEOP are:
[11] Fix | Delete
* op_next Pointer to next ppcode to execute after this one.
[12] Fix | Delete
* (Top level pre-grafted op points to first op,
[13] Fix | Delete
* but this is replaced when op is grafted in, when
[14] Fix | Delete
* this op will point to the real next op, and the new
[15] Fix | Delete
* parent takes over role of remembering starting op.)
[16] Fix | Delete
* op_ppaddr Pointer to current ppcode's function.
[17] Fix | Delete
* op_type The type of the operation.
[18] Fix | Delete
* op_opt Whether or not the op has been optimised by the
[19] Fix | Delete
* peephole optimiser.
[20] Fix | Delete
* op_slabbed allocated via opslab
[21] Fix | Delete
* op_static tell op_free() to skip PerlMemShared_free(), when
[22] Fix | Delete
* !op_slabbed.
[23] Fix | Delete
* op_savefree on savestack via SAVEFREEOP
[24] Fix | Delete
* op_folded Result/remainder of a constant fold operation.
[25] Fix | Delete
* op_moresib this op is is not the last sibling
[26] Fix | Delete
* op_spare One spare bit
[27] Fix | Delete
* op_flags Flags common to all operations. See OPf_* below.
[28] Fix | Delete
* op_private Flags peculiar to a particular operation (BUT,
[29] Fix | Delete
* by default, set to the number of children until
[30] Fix | Delete
* the operation is privatized by a check routine,
[31] Fix | Delete
* which may or may not check number of children).
[32] Fix | Delete
*/
[33] Fix | Delete
#include "op_reg_common.h"
[34] Fix | Delete
[35] Fix | Delete
#define OPCODE U16
[36] Fix | Delete
[37] Fix | Delete
typedef PERL_BITFIELD16 Optype;
[38] Fix | Delete
[39] Fix | Delete
/* this field now either points to the next sibling or to the parent,
[40] Fix | Delete
* depending on op_moresib. So rename it from op_sibling to op_sibparent.
[41] Fix | Delete
*/
[42] Fix | Delete
#ifdef PERL_OP_PARENT
[43] Fix | Delete
# define _OP_SIBPARENT_FIELDNAME op_sibparent
[44] Fix | Delete
#else
[45] Fix | Delete
# define _OP_SIBPARENT_FIELDNAME op_sibling
[46] Fix | Delete
#endif
[47] Fix | Delete
[48] Fix | Delete
#ifdef BASEOP_DEFINITION
[49] Fix | Delete
#define BASEOP BASEOP_DEFINITION
[50] Fix | Delete
#else
[51] Fix | Delete
#define BASEOP \
[52] Fix | Delete
OP* op_next; \
[53] Fix | Delete
OP* _OP_SIBPARENT_FIELDNAME;\
[54] Fix | Delete
OP* (*op_ppaddr)(pTHX); \
[55] Fix | Delete
PADOFFSET op_targ; \
[56] Fix | Delete
PERL_BITFIELD16 op_type:9; \
[57] Fix | Delete
PERL_BITFIELD16 op_opt:1; \
[58] Fix | Delete
PERL_BITFIELD16 op_slabbed:1; \
[59] Fix | Delete
PERL_BITFIELD16 op_savefree:1; \
[60] Fix | Delete
PERL_BITFIELD16 op_static:1; \
[61] Fix | Delete
PERL_BITFIELD16 op_folded:1; \
[62] Fix | Delete
PERL_BITFIELD16 op_moresib:1; \
[63] Fix | Delete
PERL_BITFIELD16 op_spare:1; \
[64] Fix | Delete
U8 op_flags; \
[65] Fix | Delete
U8 op_private;
[66] Fix | Delete
#endif
[67] Fix | Delete
[68] Fix | Delete
/* If op_type:9 is changed to :10, also change cx_pusheval()
[69] Fix | Delete
Also, if the type of op_type is ever changed (e.g. to PERL_BITFIELD32)
[70] Fix | Delete
then all the other bit-fields before/after it should change their
[71] Fix | Delete
types too to let VC pack them into the same 4 byte integer.*/
[72] Fix | Delete
[73] Fix | Delete
/* for efficiency, requires OPf_WANT_VOID == G_VOID etc */
[74] Fix | Delete
#define OP_GIMME(op,dfl) \
[75] Fix | Delete
(((op)->op_flags & OPf_WANT) ? ((op)->op_flags & OPf_WANT) : dfl)
[76] Fix | Delete
[77] Fix | Delete
#define OP_GIMME_REVERSE(flags) ((flags) & G_WANT)
[78] Fix | Delete
[79] Fix | Delete
/*
[80] Fix | Delete
=head1 "Gimme" Values
[81] Fix | Delete
[82] Fix | Delete
=for apidoc Amn|U32|GIMME_V
[83] Fix | Delete
The XSUB-writer's equivalent to Perl's C<wantarray>. Returns C<G_VOID>,
[84] Fix | Delete
C<G_SCALAR> or C<G_ARRAY> for void, scalar or list context,
[85] Fix | Delete
respectively. See L<perlcall> for a usage example.
[86] Fix | Delete
[87] Fix | Delete
=for apidoc Amn|U32|GIMME
[88] Fix | Delete
A backward-compatible version of C<GIMME_V> which can only return
[89] Fix | Delete
C<G_SCALAR> or C<G_ARRAY>; in a void context, it returns C<G_SCALAR>.
[90] Fix | Delete
Deprecated. Use C<GIMME_V> instead.
[91] Fix | Delete
[92] Fix | Delete
=cut
[93] Fix | Delete
*/
[94] Fix | Delete
[95] Fix | Delete
#define GIMME_V OP_GIMME(PL_op, block_gimme())
[96] Fix | Delete
[97] Fix | Delete
/* Public flags */
[98] Fix | Delete
[99] Fix | Delete
#define OPf_WANT 3 /* Mask for "want" bits: */
[100] Fix | Delete
#define OPf_WANT_VOID 1 /* Want nothing */
[101] Fix | Delete
#define OPf_WANT_SCALAR 2 /* Want single value */
[102] Fix | Delete
#define OPf_WANT_LIST 3 /* Want list of any length */
[103] Fix | Delete
#define OPf_KIDS 4 /* There is a firstborn child. */
[104] Fix | Delete
#define OPf_PARENS 8 /* This operator was parenthesized. */
[105] Fix | Delete
/* (Or block needs explicit scope entry.) */
[106] Fix | Delete
#define OPf_REF 16 /* Certified reference. */
[107] Fix | Delete
/* (Return container, not containee). */
[108] Fix | Delete
#define OPf_MOD 32 /* Will modify (lvalue). */
[109] Fix | Delete
#define OPf_STACKED 64 /* Some arg is arriving on the stack. */
[110] Fix | Delete
#define OPf_SPECIAL 128 /* Do something weird for this op: */
[111] Fix | Delete
/* On local LVAL, don't init local value. */
[112] Fix | Delete
/* On OP_SORT, subroutine is inlined. */
[113] Fix | Delete
/* On OP_NOT, inversion was implicit. */
[114] Fix | Delete
/* On OP_LEAVE, don't restore curpm, e.g.
[115] Fix | Delete
* /(...)/ while ...>; */
[116] Fix | Delete
/* On truncate, we truncate filehandle */
[117] Fix | Delete
/* On control verbs, we saw no label */
[118] Fix | Delete
/* On flipflop, we saw ... instead of .. */
[119] Fix | Delete
/* On UNOPs, saw bare parens, e.g. eof(). */
[120] Fix | Delete
/* On OP_CHDIR, handle (or bare parens) */
[121] Fix | Delete
/* On OP_NULL, saw a "do". */
[122] Fix | Delete
/* On OP_EXISTS, treat av as av, not avhv. */
[123] Fix | Delete
/* On OP_(ENTER|LEAVE)EVAL, don't clear $@ */
[124] Fix | Delete
/* On regcomp, "use re 'eval'" was in scope */
[125] Fix | Delete
/* On RV2[ACGHS]V, don't create GV--in
[126] Fix | Delete
defined()*/
[127] Fix | Delete
/* On OP_DBSTATE, indicates breakpoint
[128] Fix | Delete
* (runtime property) */
[129] Fix | Delete
/* On OP_REQUIRE, was seen as CORE::require */
[130] Fix | Delete
/* On OP_(ENTER|LEAVE)WHEN, there's
[131] Fix | Delete
no condition */
[132] Fix | Delete
/* On OP_SMARTMATCH, an implicit smartmatch */
[133] Fix | Delete
/* On OP_ANONHASH and OP_ANONLIST, create a
[134] Fix | Delete
reference to the new anon hash or array */
[135] Fix | Delete
/* On OP_HELEM, OP_MULTIDEREF and OP_HSLICE,
[136] Fix | Delete
localization will be followed by assignment,
[137] Fix | Delete
so do not wipe the target if it is special
[138] Fix | Delete
(e.g. a glob or a magic SV) */
[139] Fix | Delete
/* On OP_MATCH, OP_SUBST & OP_TRANS, the
[140] Fix | Delete
operand of a logical or conditional
[141] Fix | Delete
that was optimised away, so it should
[142] Fix | Delete
not be bound via =~ */
[143] Fix | Delete
/* On OP_CONST, from a constant CV */
[144] Fix | Delete
/* On OP_GLOB, two meanings:
[145] Fix | Delete
- Before ck_glob, called as CORE::glob
[146] Fix | Delete
- After ck_glob, use Perl glob function
[147] Fix | Delete
*/
[148] Fix | Delete
/* On OP_PADRANGE, push @_ */
[149] Fix | Delete
/* On OP_DUMP, has no label */
[150] Fix | Delete
/* On OP_UNSTACK, in a C-style for loop */
[151] Fix | Delete
/* There is no room in op_flags for this one, so it has its own bit-
[152] Fix | Delete
field member (op_folded) instead. The flag is only used to tell
[153] Fix | Delete
op_convert_list to set op_folded. */
[154] Fix | Delete
#define OPf_FOLDED (1<<16)
[155] Fix | Delete
[156] Fix | Delete
/* old names; don't use in new code, but don't break them, either */
[157] Fix | Delete
#define OPf_LIST OPf_WANT_LIST
[158] Fix | Delete
#define OPf_KNOW OPf_WANT
[159] Fix | Delete
[160] Fix | Delete
#if !defined(PERL_CORE) && !defined(PERL_EXT)
[161] Fix | Delete
# define GIMME \
[162] Fix | Delete
(PL_op->op_flags & OPf_WANT \
[163] Fix | Delete
? ((PL_op->op_flags & OPf_WANT) == OPf_WANT_LIST \
[164] Fix | Delete
? G_ARRAY \
[165] Fix | Delete
: G_SCALAR) \
[166] Fix | Delete
: dowantarray())
[167] Fix | Delete
#endif
[168] Fix | Delete
[169] Fix | Delete
[170] Fix | Delete
/* NOTE: OPp* flags are now auto-generated and defined in opcode.h,
[171] Fix | Delete
* from data in regen/op_private */
[172] Fix | Delete
[173] Fix | Delete
[174] Fix | Delete
#define OPpTRANS_ALL (OPpTRANS_FROM_UTF|OPpTRANS_TO_UTF|OPpTRANS_IDENTICAL|OPpTRANS_SQUASH|OPpTRANS_COMPLEMENT|OPpTRANS_GROWS|OPpTRANS_DELETE)
[175] Fix | Delete
[176] Fix | Delete
[177] Fix | Delete
[178] Fix | Delete
/* Mask for OP_ENTERSUB flags, the absence of which must be propagated
[179] Fix | Delete
in dynamic context */
[180] Fix | Delete
#define OPpENTERSUB_LVAL_MASK (OPpLVAL_INTRO|OPpENTERSUB_INARGS)
[181] Fix | Delete
[182] Fix | Delete
[183] Fix | Delete
/* things that can be elements of op_aux */
[184] Fix | Delete
typedef union {
[185] Fix | Delete
PADOFFSET pad_offset;
[186] Fix | Delete
SV *sv;
[187] Fix | Delete
IV iv;
[188] Fix | Delete
UV uv;
[189] Fix | Delete
} UNOP_AUX_item;
[190] Fix | Delete
[191] Fix | Delete
#ifdef USE_ITHREADS
[192] Fix | Delete
# define UNOP_AUX_item_sv(item) PAD_SVl((item)->pad_offset);
[193] Fix | Delete
#else
[194] Fix | Delete
# define UNOP_AUX_item_sv(item) ((item)->sv);
[195] Fix | Delete
#endif
[196] Fix | Delete
[197] Fix | Delete
[198] Fix | Delete
[199] Fix | Delete
[200] Fix | Delete
struct op {
[201] Fix | Delete
BASEOP
[202] Fix | Delete
};
[203] Fix | Delete
[204] Fix | Delete
struct unop {
[205] Fix | Delete
BASEOP
[206] Fix | Delete
OP * op_first;
[207] Fix | Delete
};
[208] Fix | Delete
[209] Fix | Delete
struct unop_aux {
[210] Fix | Delete
BASEOP
[211] Fix | Delete
OP *op_first;
[212] Fix | Delete
UNOP_AUX_item *op_aux;
[213] Fix | Delete
};
[214] Fix | Delete
[215] Fix | Delete
struct binop {
[216] Fix | Delete
BASEOP
[217] Fix | Delete
OP * op_first;
[218] Fix | Delete
OP * op_last;
[219] Fix | Delete
};
[220] Fix | Delete
[221] Fix | Delete
struct logop {
[222] Fix | Delete
BASEOP
[223] Fix | Delete
OP * op_first;
[224] Fix | Delete
OP * op_other;
[225] Fix | Delete
};
[226] Fix | Delete
[227] Fix | Delete
struct listop {
[228] Fix | Delete
BASEOP
[229] Fix | Delete
OP * op_first;
[230] Fix | Delete
OP * op_last;
[231] Fix | Delete
};
[232] Fix | Delete
[233] Fix | Delete
struct methop {
[234] Fix | Delete
BASEOP
[235] Fix | Delete
union {
[236] Fix | Delete
/* op_u.op_first *must* be aligned the same as the op_first
[237] Fix | Delete
* field of the other op types, and op_u.op_meth_sv *must*
[238] Fix | Delete
* be aligned with op_sv */
[239] Fix | Delete
OP* op_first; /* optree for method name */
[240] Fix | Delete
SV* op_meth_sv; /* static method name */
[241] Fix | Delete
} op_u;
[242] Fix | Delete
#ifdef USE_ITHREADS
[243] Fix | Delete
PADOFFSET op_rclass_targ; /* pad index for redirect class */
[244] Fix | Delete
#else
[245] Fix | Delete
SV* op_rclass_sv; /* static redirect class $o->A::meth() */
[246] Fix | Delete
#endif
[247] Fix | Delete
};
[248] Fix | Delete
[249] Fix | Delete
struct pmop {
[250] Fix | Delete
BASEOP
[251] Fix | Delete
OP * op_first;
[252] Fix | Delete
OP * op_last;
[253] Fix | Delete
#ifdef USE_ITHREADS
[254] Fix | Delete
PADOFFSET op_pmoffset;
[255] Fix | Delete
#else
[256] Fix | Delete
REGEXP * op_pmregexp; /* compiled expression */
[257] Fix | Delete
#endif
[258] Fix | Delete
U32 op_pmflags;
[259] Fix | Delete
union {
[260] Fix | Delete
OP * op_pmreplroot; /* For OP_SUBST */
[261] Fix | Delete
PADOFFSET op_pmtargetoff; /* For OP_SPLIT lex ary or thr GV */
[262] Fix | Delete
GV * op_pmtargetgv; /* For OP_SPLIT non-threaded GV */
[263] Fix | Delete
} op_pmreplrootu;
[264] Fix | Delete
union {
[265] Fix | Delete
OP * op_pmreplstart; /* Only used in OP_SUBST */
[266] Fix | Delete
#ifdef USE_ITHREADS
[267] Fix | Delete
PADOFFSET op_pmstashoff; /* Only used in OP_MATCH, with PMf_ONCE set */
[268] Fix | Delete
#else
[269] Fix | Delete
HV * op_pmstash;
[270] Fix | Delete
#endif
[271] Fix | Delete
} op_pmstashstartu;
[272] Fix | Delete
OP * op_code_list; /* list of (?{}) code blocks */
[273] Fix | Delete
};
[274] Fix | Delete
[275] Fix | Delete
#ifdef USE_ITHREADS
[276] Fix | Delete
#define PM_GETRE(o) (SvTYPE(PL_regex_pad[(o)->op_pmoffset]) == SVt_REGEXP \
[277] Fix | Delete
? (REGEXP*)(PL_regex_pad[(o)->op_pmoffset]) : NULL)
[278] Fix | Delete
/* The assignment is just to enforce type safety (or at least get a warning).
[279] Fix | Delete
*/
[280] Fix | Delete
/* With first class regexps not via a reference one needs to assign
[281] Fix | Delete
&PL_sv_undef under ithreads. (This would probably work unthreaded, but NULL
[282] Fix | Delete
is cheaper. I guess we could allow NULL, but the check above would get
[283] Fix | Delete
more complex, and we'd have an AV with (SV*)NULL in it, which feels bad */
[284] Fix | Delete
/* BEWARE - something that calls this macro passes (r) which has a side
[285] Fix | Delete
effect. */
[286] Fix | Delete
#define PM_SETRE(o,r) STMT_START { \
[287] Fix | Delete
REGEXP *const _pm_setre = (r); \
[288] Fix | Delete
assert(_pm_setre); \
[289] Fix | Delete
PL_regex_pad[(o)->op_pmoffset] = MUTABLE_SV(_pm_setre); \
[290] Fix | Delete
} STMT_END
[291] Fix | Delete
#else
[292] Fix | Delete
#define PM_GETRE(o) ((o)->op_pmregexp)
[293] Fix | Delete
#define PM_SETRE(o,r) ((o)->op_pmregexp = (r))
[294] Fix | Delete
#endif
[295] Fix | Delete
[296] Fix | Delete
/* Currently these PMf flags occupy a single 32-bit word. Not all bits are
[297] Fix | Delete
* currently used. The lower bits are shared with their corresponding RXf flag
[298] Fix | Delete
* bits, up to but not including _RXf_PMf_SHIFT_NEXT. The unused bits
[299] Fix | Delete
* immediately follow; finally the used Pmf-only (unshared) bits, so that the
[300] Fix | Delete
* highest bit in the word is used. This gathers all the unused bits as a pool
[301] Fix | Delete
* in the middle, like so: 11111111111111110000001111111111
[302] Fix | Delete
* where the '1's represent used bits, and the '0's unused. This design allows
[303] Fix | Delete
* us to allocate off one end of the pool if we need to add a shared bit, and
[304] Fix | Delete
* off the other end if we need a non-shared bit, without disturbing the other
[305] Fix | Delete
* bits. This maximizes the likelihood of being able to change things without
[306] Fix | Delete
* breaking binary compatibility.
[307] Fix | Delete
*
[308] Fix | Delete
* To add shared bits, do so in op_reg_common.h. This should change
[309] Fix | Delete
* _RXf_PMf_SHIFT_NEXT so that things won't compile. Then come to regexp.h and
[310] Fix | Delete
* op.h and adjust the constant adders in the definitions of PMf_BASE_SHIFT and
[311] Fix | Delete
* Pmf_BASE_SHIFT down by the number of shared bits you added. That's it.
[312] Fix | Delete
* Things should be binary compatible. But if either of these gets to having
[313] Fix | Delete
* to subtract rather than add, leave at 0 and adjust all the entries below
[314] Fix | Delete
* that are in terms of this according. But if the first one of those is
[315] Fix | Delete
* already PMf_BASE_SHIFT+0, there are no bits left, and a redesign is in
[316] Fix | Delete
* order.
[317] Fix | Delete
*
[318] Fix | Delete
* To remove unshared bits, just delete its entry. If you're where breaking
[319] Fix | Delete
* binary compatibility is ok to do, you might want to adjust things to move
[320] Fix | Delete
* the newly opened space so that it gets absorbed into the common pool.
[321] Fix | Delete
*
[322] Fix | Delete
* To add unshared bits, first use up any gaps in the middle. Otherwise,
[323] Fix | Delete
* allocate off the low end until you get to PMf_BASE_SHIFT+0. If that isn't
[324] Fix | Delete
* enough, move PMf_BASE_SHIFT down (if possible) and add the new bit at the
[325] Fix | Delete
* other end instead; this preserves binary compatibility. */
[326] Fix | Delete
#define PMf_BASE_SHIFT (_RXf_PMf_SHIFT_NEXT+2)
[327] Fix | Delete
[328] Fix | Delete
/* Set by the parser if it discovers an error, so the regex shouldn't be
[329] Fix | Delete
* compiled */
[330] Fix | Delete
#define PMf_HAS_ERROR (1U<<(PMf_BASE_SHIFT+4))
[331] Fix | Delete
[332] Fix | Delete
/* 'use re "taint"' in scope: taint $1 etc. if target tainted */
[333] Fix | Delete
#define PMf_RETAINT (1U<<(PMf_BASE_SHIFT+5))
[334] Fix | Delete
[335] Fix | Delete
/* match successfully only once per reset, with related flag RXf_USED in
[336] Fix | Delete
* re->extflags holding state. This is used only for ?? matches, and only on
[337] Fix | Delete
* OP_MATCH and OP_QR */
[338] Fix | Delete
#define PMf_ONCE (1U<<(PMf_BASE_SHIFT+6))
[339] Fix | Delete
[340] Fix | Delete
/* PMf_ONCE, i.e. ?pat?, has matched successfully. Not used under threading. */
[341] Fix | Delete
#define PMf_USED (1U<<(PMf_BASE_SHIFT+7))
[342] Fix | Delete
[343] Fix | Delete
/* subst replacement is constant */
[344] Fix | Delete
#define PMf_CONST (1U<<(PMf_BASE_SHIFT+8))
[345] Fix | Delete
[346] Fix | Delete
/* keep 1st runtime pattern forever */
[347] Fix | Delete
#define PMf_KEEP (1U<<(PMf_BASE_SHIFT+9))
[348] Fix | Delete
[349] Fix | Delete
#define PMf_GLOBAL (1U<<(PMf_BASE_SHIFT+10)) /* pattern had a g modifier */
[350] Fix | Delete
[351] Fix | Delete
/* don't reset pos() if //g fails */
[352] Fix | Delete
#define PMf_CONTINUE (1U<<(PMf_BASE_SHIFT+11))
[353] Fix | Delete
[354] Fix | Delete
/* evaluating replacement as expr */
[355] Fix | Delete
#define PMf_EVAL (1U<<(PMf_BASE_SHIFT+12))
[356] Fix | Delete
[357] Fix | Delete
/* Return substituted string instead of modifying it. */
[358] Fix | Delete
#define PMf_NONDESTRUCT (1U<<(PMf_BASE_SHIFT+13))
[359] Fix | Delete
[360] Fix | Delete
/* the pattern has a CV attached (currently only under qr/...(?{}).../) */
[361] Fix | Delete
#define PMf_HAS_CV (1U<<(PMf_BASE_SHIFT+14))
[362] Fix | Delete
[363] Fix | Delete
/* op_code_list is private; don't free it etc. It may well point to
[364] Fix | Delete
* code within another sub, with different pad etc */
[365] Fix | Delete
#define PMf_CODELIST_PRIVATE (1U<<(PMf_BASE_SHIFT+15))
[366] Fix | Delete
[367] Fix | Delete
/* the PMOP is a QR (we should be able to detect that from the op type,
[368] Fix | Delete
* but the regex compilation API passes just the pm flags, not the op
[369] Fix | Delete
* itself */
[370] Fix | Delete
#define PMf_IS_QR (1U<<(PMf_BASE_SHIFT+16))
[371] Fix | Delete
#define PMf_USE_RE_EVAL (1U<<(PMf_BASE_SHIFT+17)) /* use re'eval' in scope */
[372] Fix | Delete
[373] Fix | Delete
/* See comments at the beginning of these defines about adding bits. The
[374] Fix | Delete
* highest bit position should be used, so that if PMf_BASE_SHIFT gets
[375] Fix | Delete
* increased, the #error below will be triggered so that you will be reminded
[376] Fix | Delete
* to adjust things at the other end to keep the bit positions unchanged */
[377] Fix | Delete
#if PMf_BASE_SHIFT+17 > 31
[378] Fix | Delete
# error Too many PMf_ bits used. See above and regnodes.h for any spare in middle
[379] Fix | Delete
#endif
[380] Fix | Delete
[381] Fix | Delete
#ifdef USE_ITHREADS
[382] Fix | Delete
[383] Fix | Delete
# define PmopSTASH(o) ((o)->op_pmflags & PMf_ONCE \
[384] Fix | Delete
? PL_stashpad[(o)->op_pmstashstartu.op_pmstashoff] \
[385] Fix | Delete
: NULL)
[386] Fix | Delete
# define PmopSTASH_set(o,hv) \
[387] Fix | Delete
(assert_((o)->op_pmflags & PMf_ONCE) \
[388] Fix | Delete
(o)->op_pmstashstartu.op_pmstashoff = \
[389] Fix | Delete
(hv) ? alloccopstash(hv) : 0)
[390] Fix | Delete
#else
[391] Fix | Delete
# define PmopSTASH(o) \
[392] Fix | Delete
(((o)->op_pmflags & PMf_ONCE) ? (o)->op_pmstashstartu.op_pmstash : NULL)
[393] Fix | Delete
# if defined (DEBUGGING) && defined(__GNUC__) && !defined(PERL_GCC_BRACE_GROUPS_FORBIDDEN)
[394] Fix | Delete
# define PmopSTASH_set(o,hv) ({ \
[395] Fix | Delete
assert((o)->op_pmflags & PMf_ONCE); \
[396] Fix | Delete
((o)->op_pmstashstartu.op_pmstash = (hv)); \
[397] Fix | Delete
})
[398] Fix | Delete
# else
[399] Fix | Delete
# define PmopSTASH_set(o,hv) ((o)->op_pmstashstartu.op_pmstash = (hv))
[400] Fix | Delete
# endif
[401] Fix | Delete
#endif
[402] Fix | Delete
#define PmopSTASHPV(o) (PmopSTASH(o) ? HvNAME_get(PmopSTASH(o)) : NULL)
[403] Fix | Delete
/* op_pmstashstartu.op_pmstash is not refcounted */
[404] Fix | Delete
#define PmopSTASHPV_set(o,pv) PmopSTASH_set((o), gv_stashpv(pv,GV_ADD))
[405] Fix | Delete
[406] Fix | Delete
struct svop {
[407] Fix | Delete
BASEOP
[408] Fix | Delete
SV * op_sv;
[409] Fix | Delete
};
[410] Fix | Delete
[411] Fix | Delete
struct padop {
[412] Fix | Delete
BASEOP
[413] Fix | Delete
PADOFFSET op_padix;
[414] Fix | Delete
};
[415] Fix | Delete
[416] Fix | Delete
struct pvop {
[417] Fix | Delete
BASEOP
[418] Fix | Delete
char * op_pv;
[419] Fix | Delete
};
[420] Fix | Delete
[421] Fix | Delete
struct loop {
[422] Fix | Delete
BASEOP
[423] Fix | Delete
OP * op_first;
[424] Fix | Delete
OP * op_last;
[425] Fix | Delete
OP * op_redoop;
[426] Fix | Delete
OP * op_nextop;
[427] Fix | Delete
OP * op_lastop;
[428] Fix | Delete
};
[429] Fix | Delete
[430] Fix | Delete
#define cUNOPx(o) ((UNOP*)(o))
[431] Fix | Delete
#define cUNOP_AUXx(o) ((UNOP_AUX*)(o))
[432] Fix | Delete
#define cBINOPx(o) ((BINOP*)(o))
[433] Fix | Delete
#define cLISTOPx(o) ((LISTOP*)(o))
[434] Fix | Delete
#define cLOGOPx(o) ((LOGOP*)(o))
[435] Fix | Delete
#define cPMOPx(o) ((PMOP*)(o))
[436] Fix | Delete
#define cSVOPx(o) ((SVOP*)(o))
[437] Fix | Delete
#define cPADOPx(o) ((PADOP*)(o))
[438] Fix | Delete
#define cPVOPx(o) ((PVOP*)(o))
[439] Fix | Delete
#define cCOPx(o) ((COP*)(o))
[440] Fix | Delete
#define cLOOPx(o) ((LOOP*)(o))
[441] Fix | Delete
#define cMETHOPx(o) ((METHOP*)(o))
[442] Fix | Delete
[443] Fix | Delete
#define cUNOP cUNOPx(PL_op)
[444] Fix | Delete
#define cUNOP_AUX cUNOP_AUXx(PL_op)
[445] Fix | Delete
#define cBINOP cBINOPx(PL_op)
[446] Fix | Delete
#define cLISTOP cLISTOPx(PL_op)
[447] Fix | Delete
#define cLOGOP cLOGOPx(PL_op)
[448] Fix | Delete
#define cPMOP cPMOPx(PL_op)
[449] Fix | Delete
#define cSVOP cSVOPx(PL_op)
[450] Fix | Delete
#define cPADOP cPADOPx(PL_op)
[451] Fix | Delete
#define cPVOP cPVOPx(PL_op)
[452] Fix | Delete
#define cCOP cCOPx(PL_op)
[453] Fix | Delete
#define cLOOP cLOOPx(PL_op)
[454] Fix | Delete
[455] Fix | Delete
#define cUNOPo cUNOPx(o)
[456] Fix | Delete
#define cUNOP_AUXo cUNOP_AUXx(o)
[457] Fix | Delete
#define cBINOPo cBINOPx(o)
[458] Fix | Delete
#define cLISTOPo cLISTOPx(o)
[459] Fix | Delete
#define cLOGOPo cLOGOPx(o)
[460] Fix | Delete
#define cPMOPo cPMOPx(o)
[461] Fix | Delete
#define cSVOPo cSVOPx(o)
[462] Fix | Delete
#define cPADOPo cPADOPx(o)
[463] Fix | Delete
#define cPVOPo cPVOPx(o)
[464] Fix | Delete
#define cCOPo cCOPx(o)
[465] Fix | Delete
#define cLOOPo cLOOPx(o)
[466] Fix | Delete
[467] Fix | Delete
#define kUNOP cUNOPx(kid)
[468] Fix | Delete
#define kUNOP_AUX cUNOP_AUXx(kid)
[469] Fix | Delete
#define kBINOP cBINOPx(kid)
[470] Fix | Delete
#define kLISTOP cLISTOPx(kid)
[471] Fix | Delete
#define kLOGOP cLOGOPx(kid)
[472] Fix | Delete
#define kPMOP cPMOPx(kid)
[473] Fix | Delete
#define kSVOP cSVOPx(kid)
[474] Fix | Delete
#define kPADOP cPADOPx(kid)
[475] Fix | Delete
#define kPVOP cPVOPx(kid)
[476] Fix | Delete
#define kCOP cCOPx(kid)
[477] Fix | Delete
#define kLOOP cLOOPx(kid)
[478] Fix | Delete
[479] Fix | Delete
[480] Fix | Delete
typedef enum {
[481] Fix | Delete
OPclass_NULL, /* 0 */
[482] Fix | Delete
OPclass_BASEOP, /* 1 */
[483] Fix | Delete
OPclass_UNOP, /* 2 */
[484] Fix | Delete
OPclass_BINOP, /* 3 */
[485] Fix | Delete
OPclass_LOGOP, /* 4 */
[486] Fix | Delete
OPclass_LISTOP, /* 5 */
[487] Fix | Delete
OPclass_PMOP, /* 6 */
[488] Fix | Delete
OPclass_SVOP, /* 7 */
[489] Fix | Delete
OPclass_PADOP, /* 8 */
[490] Fix | Delete
OPclass_PVOP, /* 9 */
[491] Fix | Delete
OPclass_LOOP, /* 10 */
[492] Fix | Delete
OPclass_COP, /* 11 */
[493] Fix | Delete
OPclass_METHOP, /* 12 */
[494] Fix | Delete
OPclass_UNOP_AUX /* 13 */
[495] Fix | Delete
} OPclass;
[496] Fix | Delete
[497] Fix | Delete
[498] Fix | Delete
#ifdef USE_ITHREADS
[499] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function