sv_refcnt SvREFCNT(bstate->bs_sv) U32
sv_refcnt_add SvREFCNT(bstate->bs_sv) I32 x
sv_flags SvFLAGS(bstate->bs_sv) U32
-xrv SvRV(bstate->bs_sv) svindex
+xrv bstate->bs_sv svindex x
xpv bstate->bs_sv none x
-xpv_cur SvCUR(bstate->bs_sv) STRLEN
-xpv_len SvLEN(bstate->bs_sv) STRLEN
-xiv SvIVX(bstate->bs_sv) IV
-xnv SvNVX(bstate->bs_sv) NV
+xpv_cur bstate->bs_sv STRLEN x
+xpv_len bstate->bs_sv STRLEN x
+xiv bstate->bs_sv IV x
+xnv bstate->bs_sv NV x
xlv_targoff LvTARGOFF(bstate->bs_sv) STRLEN
xlv_targlen LvTARGLEN(bstate->bs_sv) STRLEN
xlv_targ LvTARG(bstate->bs_sv) svindex
mg_flags SvMAGIC(bstate->bs_sv)->mg_flags U8
mg_name SvMAGIC(bstate->bs_sv) pvcontents x
mg_namex SvMAGIC(bstate->bs_sv) svindex x
-xmg_stash *(SV**)&SvSTASH(bstate->bs_sv) svindex
+xmg_stash bstate->bs_sv svindex X
gv_fetchpv bstate->bs_sv strconst x
gv_fetchpvx bstate->bs_sv strconst x
gv_stashpv bstate->bs_sv strconst x
#define BSET_mg_namex(mg, arg) \
(mg->mg_ptr = (char*)SvREFCNT_inc((SV*)arg), \
mg->mg_len = HEf_SVKEY)
+#define BSET_xmg_stash(sv, arg) SvSTASH_set(sv, arg)
#define BSET_sv_upgrade(sv, arg) (void)SvUPGRADE(sv, arg)
+#define BSET_xrv(sv, arg) SvRV_set(sv, arg)
#define BSET_xpv(sv) do { \
SvPV_set(sv, bstate->bs_pv.xpv_pv); \
SvCUR_set(sv, bstate->bs_pv.xpv_cur); \
SvLEN_set(sv, bstate->bs_pv.xpv_len); \
} while (0)
+#define BSET_xpv_cur(sv, arg) SvCUR_set(sv, arg)
+#define BSET_xpv_len(sv, arg) SvLEN_set(sv, arg)
+#define BSET_xiv(sv, arg) SvIV_set(sv, arg)
+#define BSET_xnv(sv, arg) SvNV_set(sv, arg)
+
#define BSET_av_extend(sv, arg) av_extend((AV*)sv, arg)
#define BSET_av_push(sv, arg) av_push((AV*)sv, arg)
SvPOK_off(sv);
SvPV_set(sv, Nullch);
- SvCUR(sv) = SvLEN(sv) = 0;
+ SvCUR_set(sv, 0);
+ SvLEN_set(sv, 0);
*size = malloced_size(pv) + M_OVERHEAD;
return pv - sizeof(union overhead);
}
(sflags & SVf_UTF8?-cur:cur), hash));
SvUV_set(dstr, hash);
}
- SvLEN(dstr) = len;
- SvCUR(dstr) = cur;
+ SvLEN_set(dstr, len);
+ SvCUR_set(dstr, cur);
SvREADONLY_on(dstr);
SvFAKE_on(dstr);
/* Relesase a global SV mutex. */
SvFLAGS(dstr) = (SVt_PVIV|SVf_POK|SVp_POK|SVf_FAKE|SVf_READONLY);
if (SvUTF8(sstr))
SvUTF8_on(dstr);
- SvLEN(dstr) = len;
- SvCUR(dstr) = cur;
+ SvLEN_set(dstr, len);
+ SvCUR_set(dstr, cur);
if (DEBUG_C_TEST) {
sv_dump(dstr);
}
SvREADONLY_off(sv);
/* This SV doesn't own the buffer, so need to New() a new one: */
SvPV_set(sv, (char*)0);
- SvLEN(sv) = 0;
+ SvLEN_set(sv, 0);
if (flags & SV_COW_DROP_PV) {
/* OK, so we don't need to copy our buffer. */
SvPOK_off(sv);
} else {
SvGROW(sv, cur + 1);
Move(pvx,SvPVX(sv),cur,char);
- SvCUR(sv) = cur;
+ SvCUR_set(sv, cur);
*SvEND(sv) = '\0';
}
sv_release_COW(sv, pvx, cur, len, hash, next);