You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
PR-URL: #52473
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
* @param length the length of the string in 2-byte code units (char16_t)
1478
1482
* @param latin1_buffer the pointer to buffer that can hold conversion result
1479
-
* @return a result pair struct (of type simdutf::error containing the two fields error and count) with an error code and either position of the error (in the input in code units) if any, or the number of char written if successful.
1483
+
* @return number of written code units; 0 if input is not a valid UTF-16BE string or if it cannot be represented as Latin1
* @param length the length of the string in 2-byte code units (char16_t)
2879
2888
* @param latin1_buffer the pointer to buffer that can hold conversion result
2880
-
* @return a result pair struct (of type simdutf::error containing the two fields error and count) with an error code and either position of the error (in the input in code units) if any, or the number of char written if successful.
2889
+
* @return number of written code units; 0 if input is not a valid UTF-16BE string or if it cannot be represented as Latin1
* Convert possibly broken UTF-16LE string into Latin1 string.
2895
+
* If the string cannot be represented as Latin1, an error
2896
+
* is returned.
2886
2897
*
2887
2898
* During the conversion also validation of the input string is done.
2888
2899
* This function is suitable to work with inputs from untrusted sources.
@@ -2897,6 +2908,8 @@ class implementation {
2897
2908
2898
2909
/**
2899
2910
* Convert possibly broken UTF-16BE string into Latin1 string.
2911
+
* If the string cannot be represented as Latin1, an error
2912
+
* is returned.
2900
2913
*
2901
2914
* During the conversion also validation of the input string is done.
2902
2915
* This function is suitable to work with inputs from untrusted sources.
@@ -3157,6 +3170,7 @@ class implementation {
3157
3170
3158
3171
/**
3159
3172
* Convert possibly broken UTF-32 string into Latin1 string and stop on error.
3173
+
* If the string cannot be represented as Latin1, an error is returned.
3160
3174
*
3161
3175
* During the conversion also validation of the input string is done.
3162
3176
* This function is suitable to work with inputs from untrusted sources.
@@ -3168,7 +3182,6 @@ class implementation {
3168
3182
* @param latin1_buffer the pointer to buffer that can hold conversion result
3169
3183
* @return a result pair struct (of type simdutf::error containing the two fields error and count) with an error code and either position of the error (in the input in code units) if any, or the number of char written if successful.
0 commit comments