X-Git-Url: https://perl5.git.perl.org/perl5.git/blobdiff_plain/9c3dd3fe0ef5ca1dd7e835adfcf5e21c1099e72a..d57b1ce7265517b8de654c83dd85f8a9389ca311:/sv.c diff --git a/sv.c b/sv.c index f062bbb..f6f49d2 100644 --- a/sv.c +++ b/sv.c @@ -4743,6 +4743,25 @@ Perl_newSViv(pTHX_ IV i) } /* +=for apidoc newSVuv + +Creates a new SV and copies an unsigned integer into it. +The reference count for the SV is set to 1. + +=cut +*/ + +SV * +Perl_newSVuv(pTHX_ UV u) +{ + register SV *sv; + + new_SV(sv); + sv_setuv(sv,u); + return sv; +} + +/* =for apidoc newRV_noinc Creates an RV wrapper for an SV. The reference count for the original @@ -5168,6 +5187,7 @@ Perl_sv_reftype(pTHX_ SV *sv, int ob) case SVt_PVCV: return "CODE"; case SVt_PVGV: return "GLOB"; case SVt_PVFM: return "FORMAT"; + case SVt_PVIO: return "IO"; default: return "UNKNOWN"; } } @@ -5824,7 +5844,7 @@ Perl_sv_vcatpvfn(pTHX_ SV *sv, const char *pat, STRLEN patlen, va_list *args, SV else if (svix < svmax) vecsv = svargs[svix++]; else { - vecstr = ""; + vecstr = (U8*)""; veclen = 0; continue; } @@ -6382,10 +6402,6 @@ Perl_sv_vcatpvfn(pTHX_ SV *sv, const char *pat, STRLEN patlen, va_list *args, SV # include "error: USE_THREADS and USE_ITHREADS are incompatible" #endif -#ifndef OpREFCNT_inc -# define OpREFCNT_inc(o) ((o) ? (++(o)->op_targ, (o)) : Nullop) -#endif - #ifndef GpREFCNT_inc # define GpREFCNT_inc(gp) ((gp) ? (++(gp)->gp_refcnt, (gp)) : (GP*)NULL) #endif