diff options
author | Pali <pali@cpan.org> | 2019-02-07 14:10:35 +0100 |
---|---|---|
committer | Tony Cook <tony@develop-help.com> | 2019-02-25 10:17:20 +1100 |
commit | 238f2c136aa0ab2a1070f175ec56ef61b91ff79d (patch) | |
tree | a26c69376275007668459851661f8f1793bfacd9 /sv.h | |
parent | 929e53be972b0c811eca54a3c7017db116f62e4a (diff) | |
download | perl-238f2c136aa0ab2a1070f175ec56ef61b91ff79d.tar.gz |
Add newSVsv_nomg() macro which is like newSVsv() but does not process get magic
Both newSVsv() and newSVsv_nomg() are now implemented via new Perl_newSVsv_flags() function.
Diffstat (limited to 'sv.h')
-rw-r--r-- | sv.h | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -2175,6 +2175,11 @@ struct clone_params { AV *unreferenced; }; +/* SV_NOSTEAL prevents TEMP buffers being, well, stolen, and saves games + with SvTEMP_off and SvTEMP_on round a call to sv_setsv. */ +#define newSVsv(sv) newSVsv_flags((sv), SV_GMAGIC|SV_NOSTEAL) +#define newSVsv_nomg(sv) newSVsv_flags((sv), SV_NOSTEAL) + /* =for apidoc Am|SV*|newSVpvn_utf8|const char* s|STRLEN len|U32 utf8 |