summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--perlapi.c4
-rw-r--r--pod/perlapi.pod46
-rw-r--r--utf8.c2
3 files changed, 31 insertions, 21 deletions
diff --git a/perlapi.c b/perlapi.c
index 496fcc9318..614f94f531 100644
--- a/perlapi.c
+++ b/perlapi.c
@@ -3380,9 +3380,9 @@ Perl_bytes_to_utf8(pTHXo_ U8 *s, STRLEN *len)
#undef Perl_utf8_to_uv
UV
-Perl_utf8_to_uv(pTHXo_ U8 *s, I32* retlen)
+Perl_utf8_to_uv(pTHXo_ U8 *s, I32* retlen, bool checking)
{
- return ((CPerlObj*)pPerl)->Perl_utf8_to_uv(s, retlen);
+ return ((CPerlObj*)pPerl)->Perl_utf8_to_uv(s, retlen, checking);
}
#undef Perl_uv_to_utf8
diff --git a/pod/perlapi.pod b/pod/perlapi.pod
index ca2ba7c834..5d5bc5f4b9 100644
--- a/pod/perlapi.pod
+++ b/pod/perlapi.pod
@@ -2355,19 +2355,19 @@ false, defined or undefined. Does not handle 'get' magic.
=for hackers
Found in file sv.h
-=item SvTYPE
-
-Returns the type of the SV. See C<svtype>.
+=item svtype
- svtype SvTYPE(SV* sv)
+An enum of flags for Perl types. These are found in the file B<sv.h>
+in the C<svtype> enum. Test these flags with the C<SvTYPE> macro.
=for hackers
Found in file sv.h
-=item svtype
+=item SvTYPE
-An enum of flags for Perl types. These are found in the file B<sv.h>
-in the C<svtype> enum. Test these flags with the C<SvTYPE> macro.
+Returns the type of the SV. See C<svtype>.
+
+ svtype SvTYPE(SV* sv)
=for hackers
Found in file sv.h
@@ -3182,18 +3182,10 @@ Found in file handy.h
=item U8 *s
-Returns the character value of the first character in the string C<s>
-which is assumed to be in UTF8 encoding; C<retlen> will be set to the
-length, in bytes, of that character, and the pointer C<s> will be
-advanced to the end of the character.
-
-If C<s> does not point to a well-formed UTF8 character, the behaviour
-is dependent on the value of C<checking>: if this is true, it is
-assumed that the caller will raise a warning, and this function will
-set C<retlen> to C<-1> and return. If C<checking> is not true, an optional UTF8
-warning is produced.
+Returns true if first C<len> bytes of the given string form valid a UTF8
+string, false otherwise.
- utf8_to_uv U8 *s(I32 *retlen, I32 checking)
+ is_utf8_string U8 *s(STRLEN len)
=for hackers
Found in file utf8.c
@@ -3210,6 +3202,24 @@ Returns zero on failure, setting C<len> to -1.
=for hackers
Found in file utf8.c
+=item utf8_to_uv
+
+Returns the character value of the first character in the string C<s>
+which is assumed to be in UTF8 encoding; C<retlen> will be set to the
+length, in bytes, of that character, and the pointer C<s> will be
+advanced to the end of the character.
+
+If C<s> does not point to a well-formed UTF8 character, the behaviour
+is dependent on the value of C<checking>: if this is true, it is
+assumed that the caller will raise a warning, and this function will
+set C<retlen> to C<-1> and return. If C<checking> is not true, an optional UTF8
+warning is produced.
+
+ U8* s utf8_to_uv(I32 *retlen, I32 checking)
+
+=for hackers
+Found in file utf8.c
+
=item warn
This is the XSUB-writer's interface to Perl's C<warn> function. Use this
diff --git a/utf8.c b/utf8.c
index d97a8b003d..d23c9f7bc7 100644
--- a/utf8.c
+++ b/utf8.c
@@ -159,7 +159,7 @@ Perl_is_utf8_string(pTHX_ U8 *s, STRLEN len)
}
/*
-=for apidoc Am|utf8_to_uv|U8 *s|I32 *retlen|I32 checking
+=for apidoc Am|U8* s|utf8_to_uv|I32 *retlen|I32 checking
Returns the character value of the first character in the string C<s>
which is assumed to be in UTF8 encoding; C<retlen> will be set to the