📄 sv.h
字号:
/* PVHV */#define SVphv_HASKFLAGS 0x80000000 /* keys have flag byte after hash *//* PVFM */#define SVpfm_COMPILED 0x80000000 /* FORMLINE is compiled *//* PVGV when SVpbm_VALID is true */#define SVpbm_TAIL 0x80000000/* RV upwards. However, SVf_ROK and SVp_IOK are exclusive */#define SVprv_WEAKREF 0x80000000 /* Weak reference */struct xpv { union { NV xnv_nv; /* numeric value, if any */ HV * xgv_stash; struct { U32 xlow; U32 xhigh; } xpad_cop_seq; /* used by pad.c for cop_sequence */ struct { U32 xbm_previous; /* how many characters in string before rare? */ U8 xbm_flags; U8 xbm_rare; /* rarest character in string */ } xbm_s; /* fields from PVBM */ } xnv_u; STRLEN xpv_cur; /* length of svu_pv as a C string */ STRLEN xpv_len; /* allocated size */};typedef struct { STRLEN xpv_cur; /* length of svu_pv as a C string */ STRLEN xpv_len; /* allocated size */} xpv_allocated;struct xpviv { union { NV xnv_nv; /* numeric value, if any */ HV * xgv_stash; struct { U32 xlow; U32 xhigh; } xpad_cop_seq; /* used by pad.c for cop_sequence */ struct { U32 xbm_previous; /* how many characters in string before rare? */ U8 xbm_flags; U8 xbm_rare; /* rarest character in string */ } xbm_s; /* fields from PVBM */ } xnv_u; STRLEN xpv_cur; /* length of svu_pv as a C string */ STRLEN xpv_len; /* allocated size */ union { IV xivu_iv; /* integer value or pv offset */ UV xivu_uv; void * xivu_p1; I32 xivu_i32; HEK * xivu_namehek; } xiv_u;};typedef struct { STRLEN xpv_cur; /* length of svu_pv as a C string */ STRLEN xpv_len; /* allocated size */ union { IV xivu_iv; /* integer value or pv offset */ UV xivu_uv; void * xivu_p1; I32 xivu_i32; HEK * xivu_namehek; } xiv_u;} xpviv_allocated;#define xiv_iv xiv_u.xivu_ivstruct xpvuv { union { NV xnv_nv; /* numeric value, if any */ HV * xgv_stash; struct { U32 xlow; U32 xhigh; } xpad_cop_seq; /* used by pad.c for cop_sequence */ struct { U32 xbm_previous; /* how many characters in string before rare? */ U8 xbm_flags; U8 xbm_rare; /* rarest character in string */ } xbm_s; /* fields from PVBM */ } xnv_u; STRLEN xpv_cur; /* length of svu_pv as a C string */ STRLEN xpv_len; /* allocated size */ union { IV xuvu_iv; UV xuvu_uv; /* unsigned value or pv offset */ void * xuvu_p1; HEK * xivu_namehek; } xuv_u;};#define xuv_uv xuv_u.xuvu_uvstruct xpvnv { union { NV xnv_nv; /* numeric value, if any */ HV * xgv_stash; struct { U32 xlow; U32 xhigh; } xpad_cop_seq; /* used by pad.c for cop_sequence */ struct { U32 xbm_previous; /* how many characters in string before rare? */ U8 xbm_flags; U8 xbm_rare; /* rarest character in string */ } xbm_s; /* fields from PVBM */ } xnv_u; STRLEN xpv_cur; /* length of svu_pv as a C string */ STRLEN xpv_len; /* allocated size */ union { IV xivu_iv; /* integer value or pv offset */ UV xivu_uv; void * xivu_p1; I32 xivu_i32; HEK * xivu_namehek; } xiv_u;};/* These structure must match the beginning of struct xpvhv in hv.h. */struct xpvmg { union { NV xnv_nv; /* numeric value, if any */ HV * xgv_stash; struct { U32 xlow; U32 xhigh; } xpad_cop_seq; /* used by pad.c for cop_sequence */ struct { U32 xbm_previous; /* how many characters in string before rare? */ U8 xbm_flags; U8 xbm_rare; /* rarest character in string */ } xbm_s; /* fields from PVBM */ } xnv_u; STRLEN xpv_cur; /* length of svu_pv as a C string */ STRLEN xpv_len; /* allocated size */ union { IV xivu_iv; /* integer value or pv offset */ UV xivu_uv; void * xivu_p1; I32 xivu_i32; HEK * xivu_namehek; } xiv_u; union { MAGIC* xmg_magic; /* linked list of magicalness */ HV* xmg_ourstash; /* Stash for our (when SvPAD_OUR is true) */ } xmg_u; HV* xmg_stash; /* class package */};struct xpvlv { union { NV xnv_nv; /* numeric value, if any */ HV * xgv_stash; struct { U32 xlow; U32 xhigh; } xpad_cop_seq; /* used by pad.c for cop_sequence */ struct { U32 xbm_previous; /* how many characters in string before rare? */ U8 xbm_flags; U8 xbm_rare; /* rarest character in string */ } xbm_s; /* fields from PVBM */ } xnv_u; STRLEN xpv_cur; /* length of svu_pv as a C string */ STRLEN xpv_len; /* allocated size */ union { IV xivu_iv; /* integer value or pv offset */ UV xivu_uv; void * xivu_p1; I32 xivu_i32; HEK * xivu_namehek; /* GvNAME */ } xiv_u; union { MAGIC* xmg_magic; /* linked list of magicalness */ HV* xmg_ourstash; /* Stash for our (when SvPAD_OUR is true) */ } xmg_u; HV* xmg_stash; /* class package */ STRLEN xlv_targoff; STRLEN xlv_targlen; SV* xlv_targ; char xlv_type; /* k=keys .=pos x=substr v=vec /=join/re * y=alem/helem/iter t=tie T=tied HE */};/* This structure works in 3 ways - regular scalar, GV with GP, or fast Boyer-Moore. */struct xpvgv { union { NV xnv_nv; HV * xgv_stash; /* The stash of this GV */ struct { U32 xlow; U32 xhigh; } xpad_cop_seq; /* used by pad.c for cop_sequence */ struct { U32 xbm_previous; /* how many characters in string before rare? */ U8 xbm_flags; U8 xbm_rare; /* rarest character in string */ } xbm_s; /* fields from PVBM */ } xnv_u; STRLEN xpv_cur; /* xgv_flags */ STRLEN xpv_len; /* 0 */ union { IV xivu_iv; UV xivu_uv; void * xivu_p1; I32 xivu_i32; /* is this constant pattern being useful? */ HEK * xivu_namehek; /* GvNAME */ } xiv_u; union { MAGIC* xmg_magic; /* linked list of magicalness */ HV* xmg_ourstash; /* Stash for our (when SvPAD_OUR is true) */ } xmg_u; HV* xmg_stash; /* class package */};/* This structure must match XPVCV in cv.h */typedef U16 cv_flags_t;struct xpvfm { union { NV xnv_nv; /* numeric value, if any */ HV * xgv_stash; struct { U32 xlow; U32 xhigh; } xpad_cop_seq; /* used by pad.c for cop_sequence */ struct { U32 xbm_previous; /* how many characters in string before rare? */ U8 xbm_flags; U8 xbm_rare; /* rarest character in string */ } xbm_s; /* fields from PVBM */ } xnv_u; STRLEN xpv_cur; /* length of svu_pv as a C string */ STRLEN xpv_len; /* allocated size */ union { IV xivu_iv; /* PVFMs use the pv offset */ UV xivu_uv; void * xivu_p1; I32 xivu_i32; HEK * xivu_namehek; } xiv_u; union { MAGIC* xmg_magic; /* linked list of magicalness */ HV* xmg_ourstash; /* Stash for our (when SvPAD_OUR is true) */ } xmg_u; HV* xmg_stash; /* class package */ HV * xcv_stash; union { OP * xcv_start; ANY xcv_xsubany; } xcv_start_u; union { OP * xcv_root; void (*xcv_xsub) (pTHX_ CV*); } xcv_root_u; GV * xcv_gv; char * xcv_file; AV * xcv_padlist; CV * xcv_outside; U32 xcv_outside_seq; /* the COP sequence (at the point of our * compilation) in the lexically enclosing * sub */ cv_flags_t xcv_flags; IV xfm_lines;};typedef struct { STRLEN xpv_cur; /* length of svu_pv as a C string */ STRLEN xpv_len; /* allocated size */ union { IV xivu_iv; /* PVFMs use the pv offset */ UV xivu_uv; void * xivu_p1; I32 xivu_i32; HEK * xivu_namehek; } xiv_u; union { MAGIC* xmg_magic; /* linked list of magicalness */ HV* xmg_ourstash; /* Stash for our (when SvPAD_OUR is true) */ } xmg_u; HV* xmg_stash; /* class package */ HV * xcv_stash; union { OP * xcv_start; ANY xcv_xsubany; } xcv_start_u; union { OP * xcv_root; void (*xcv_xsub) (pTHX_ CV*); } xcv_root_u; GV * xcv_gv; char * xcv_file; AV * xcv_padlist; CV * xcv_outside; U32 xcv_outside_seq; /* the COP sequence (at the point of our * compilation) in the lexically enclosing * sub */ cv_flags_t xcv_flags; IV xfm_lines;} xpvfm_allocated;struct xpvio { union { NV xnv_nv; /* numeric value, if any */ HV * xgv_stash; struct { U32 xlow; U32 xhigh; } xpad_cop_seq; /* used by pad.c for cop_sequence */ struct { U32 xbm_previous; /* how many characters in string before rare? */ U8 xbm_flags; U8 xbm_rare; /* rarest character in string */ } xbm_s; /* fields from PVBM */ } xnv_u; STRLEN xpv_cur; /* length of svu_pv as a C string */ STRLEN xpv_len; /* allocated size */ union { IV xivu_iv; /* integer value or pv offset */ UV xivu_uv; void * xivu_p1; I32 xivu_i32; HEK * xivu_namehek; } xiv_u; union { MAGIC* xmg_magic; /* linked list of magicalness */ HV* xmg_ourstash; /* Stash for our (when SvPAD_OUR is true) */ } xmg_u; HV* xmg_stash; /* class package */ PerlIO * xio_ifp; /* ifp and ofp are normally the same */ PerlIO * xio_ofp; /* but sockets need separate streams */ /* Cray addresses everything by word boundaries (64 bits) and * code and data pointers cannot be mixed (which is exactly what * Perl_filter_add() tries to do with the dirp), hence the following * union trick (as suggested by Gurusamy Sarathy). * For further information see Geir Johansen's problem report titled [ID 20000612.002] Perl problem on Cray system * The any pointer (known as IoANY()) will also be a good place * to hang any IO disciplines to. */ union { DIR * xiou_dirp; /* for opendir, readdir, etc */ void * xiou_any; /* for alignment */ } xio_dirpu; IV xio_lines; /* $. */ IV xio_page; /* $% */ IV xio_page_len; /* $= */ IV xio_lines_left; /* $- */ char * xio_top_name; /* $^ */ GV * xio_top_gv; /* $^ */ char * xio_fmt_name; /* $~ */ GV * xio_fmt_gv; /* $~ */ char * xio_bottom_name;/* $^B */ GV * xio_bottom_gv; /* $^B */ char xio_type; U8 xio_flags;};#define xio_dirp xio_dirpu.xiou_dirp#define xio_any xio_dirpu.xiou_any#define IOf_ARGV 1 /* this fp iterates over ARGV */#define IOf_START 2 /* check for null ARGV and substitute '-' */#define IOf_FLUSH 4 /* this fp wants a flush after write op */#define IOf_DIDTOP 8 /* just did top of form */#define IOf_UNTAINT 16 /* consider this fp (and its data) "safe" */#define IOf_NOLINE 32 /* slurped a pseudo-line from empty file */#define IOf_FAKE_DIRP 64 /* xio_dirp is fake (source filters kludge) *//* The following macros define implementation-independent predicates on SVs. */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -