diff options
author | Yves Orton <demerphq@gmail.com> | 2016-10-19 10:40:29 +0200 |
---|---|---|
committer | Yves Orton <demerphq@gmail.com> | 2016-10-19 13:27:59 +0200 |
commit | 45661033e6be88d16397139fbd546cb1c7f8cd56 (patch) | |
tree | 4faf5988e1671db667cd36d29ae14240f6ec74f8 /proto.h | |
parent | 4ac46235a35c3293a6effa2b38b5fe6e37ef7985 (diff) | |
download | perl-45661033e6be88d16397139fbd546cb1c7f8cd56.tar.gz |
sv.c: add sv_setpv_bufsize() and SvPVCLEAR()
The first can be used to wrap several SVPV steps into
a single sub, and a wrapper macro which is the equivalent
of
$s= "";
but is optimized in various ways.
Diffstat (limited to 'proto.h')
-rw-r--r-- | proto.h | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -3251,6 +3251,9 @@ PERL_CALLCONV void Perl_sv_setnv_mg(pTHX_ SV *const sv, const NV num); PERL_CALLCONV void Perl_sv_setpv(pTHX_ SV *const sv, const char *const ptr); #define PERL_ARGS_ASSERT_SV_SETPV \ assert(sv) +PERL_CALLCONV char * Perl_sv_setpv_bufsize(pTHX_ SV *const sv, const STRLEN cur, const STRLEN len); +#define PERL_ARGS_ASSERT_SV_SETPV_BUFSIZE \ + assert(sv) PERL_CALLCONV void Perl_sv_setpv_mg(pTHX_ SV *const sv, const char *const ptr); #define PERL_ARGS_ASSERT_SV_SETPV_MG \ assert(sv) |