X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=sv.h;h=e99891dd22c0efc25d1a3f6bdc8dec4108f72f48;hb=ae178db11db50e8d46c66980e186cfba029f0cb9;hp=0476a12e6c8ecdd32d4eb3c6a05dea6dc4e5212c;hpb=20ce7b12268a3d32b5b246928de5084322e709cf;p=p5sagit%2Fp5-mst-13.2.git diff --git a/sv.h b/sv.h index 0476a12..e99891d 100644 --- a/sv.h +++ b/sv.h @@ -153,6 +153,8 @@ struct io { /* Some private flags. */ +#define SVpad_OUR 0x80000000 /* pad name is "our" instead of "my" */ + #define SVf_IVisUV 0x80000000 /* use XPVUV instead of XPVIV */ #define SVpfm_COMPILED 0x80000000 /* FORMLINE is compiled */ @@ -196,7 +198,7 @@ struct xpvnv { STRLEN xpv_cur; /* length of xpv_pv as a C string */ STRLEN xpv_len; /* allocated size */ IV xiv_iv; /* integer value or pv offset */ - double xnv_nv; /* numeric value, if any */ + NV xnv_nv; /* numeric value, if any */ }; /* These structure must match the beginning of struct xpvhv in hv.h. */ @@ -205,7 +207,7 @@ struct xpvmg { STRLEN xpv_cur; /* length of xpv_pv as a C string */ STRLEN xpv_len; /* allocated size */ IV xiv_iv; /* integer value or pv offset */ - double xnv_nv; /* numeric value, if any */ + NV xnv_nv; /* numeric value, if any */ MAGIC* xmg_magic; /* linked list of magicalness */ HV* xmg_stash; /* class package */ }; @@ -215,7 +217,7 @@ struct xpvlv { STRLEN xpv_cur; /* length of xpv_pv as a C string */ STRLEN xpv_len; /* allocated size */ IV xiv_iv; /* integer value or pv offset */ - double xnv_nv; /* numeric value, if any */ + NV xnv_nv; /* numeric value, if any */ MAGIC* xmg_magic; /* linked list of magicalness */ HV* xmg_stash; /* class package */ @@ -230,7 +232,7 @@ struct xpvgv { STRLEN xpv_cur; /* length of xpv_pv as a C string */ STRLEN xpv_len; /* allocated size */ IV xiv_iv; /* integer value or pv offset */ - double xnv_nv; /* numeric value, if any */ + NV xnv_nv; /* numeric value, if any */ MAGIC* xmg_magic; /* linked list of magicalness */ HV* xmg_stash; /* class package */ @@ -246,7 +248,7 @@ struct xpvbm { STRLEN xpv_cur; /* length of xpv_pv as a C string */ STRLEN xpv_len; /* allocated size */ IV xiv_iv; /* integer value or pv offset */ - double xnv_nv; /* numeric value, if any */ + NV xnv_nv; /* numeric value, if any */ MAGIC* xmg_magic; /* linked list of magicalness */ HV* xmg_stash; /* class package */ @@ -264,14 +266,14 @@ struct xpvfm { STRLEN xpv_cur; /* length of xpv_pv as a C string */ STRLEN xpv_len; /* allocated size */ IV xiv_iv; /* integer value or pv offset */ - double xnv_nv; /* numeric value, if any */ + NV xnv_nv; /* numeric value, if any */ MAGIC* xmg_magic; /* linked list of magicalness */ HV* xmg_stash; /* class package */ HV * xcv_stash; OP * xcv_start; OP * xcv_root; - void (*xcv_xsub)(CV* _CPERLproto); + void (*xcv_xsub)(pTHXo_ CV*); ANY xcv_xsubany; GV * xcv_gv; GV * xcv_filegv; @@ -292,7 +294,7 @@ struct xpvio { STRLEN xpv_cur; /* length of xpv_pv as a C string */ STRLEN xpv_len; /* allocated size */ IV xiv_iv; /* integer value or pv offset */ - double xnv_nv; /* numeric value, if any */ + NV xnv_nv; /* numeric value, if any */ MAGIC* xmg_magic; /* linked list of magicalness */ HV* xmg_stash; /* class package */ @@ -692,12 +694,5 @@ struct xpvio { #define isGV(sv) (SvTYPE(sv) == SVt_PVGV) -#ifndef DOSISH -# define SvGROW(sv,len) (SvLEN(sv) < (len) ? sv_grow(sv,len) : SvPVX(sv)) -# define Sv_Grow sv_grow -#else - /* extra parentheses intentionally NOT placed around "len"! */ -# define SvGROW(sv,len) ((SvLEN(sv) < (unsigned long)len) \ - ? sv_grow(sv,(unsigned long)len) : SvPVX(sv)) -# define Sv_Grow(sv,len) sv_grow(sv,(unsigned long)(len)) -#endif /* DOSISH */ +#define SvGROW(sv,len) (SvLEN(sv) < (len) ? sv_grow(sv,len) : SvPVX(sv)) +#define Sv_Grow sv_grow