Skip to content

Commit 195dfb0

Browse files
committed
Update mbstring names
1 parent 56fb686 commit 195dfb0

14 files changed

+63
-63
lines changed

ext/mbstring/mbstring.stub.php

+21-21
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ function mb_parse_str(string $encoded_string, &$result): bool {}
2121

2222
function mb_output_handler(string $contents, int $status): string {}
2323

24-
function mb_str_split(string $string, int $split_length = 1, ?string $encoding = null): array {}
24+
function mb_str_split(string $string, int $length = 1, ?string $encoding = null): array {}
2525

2626
function mb_strlen(string $string, ?string $encoding = null): int {}
2727

@@ -33,13 +33,13 @@ function mb_stripos(string $haystack, string $needle, int $offset = 0, ?string $
3333

3434
function mb_strripos(string $haystack, string $needle, int $offset = 0, ?string $encoding = null): int|false {}
3535

36-
function mb_strstr(string $haystack, string $needle, bool $part = false, ?string $encoding = null): string|false {}
36+
function mb_strstr(string $haystack, string $needle, bool $before_needle = false, ?string $encoding = null): string|false {}
3737

38-
function mb_strrchr(string $haystack, string $needle, bool $part = false, ?string $encoding = null): string|false {}
38+
function mb_strrchr(string $haystack, string $needle, bool $before_needle = false, ?string $encoding = null): string|false {}
3939

40-
function mb_stristr(string $haystack, string $needle, bool $part = false, ?string $encoding = null): string|false {}
40+
function mb_stristr(string $haystack, string $needle, bool $before_needle = false, ?string $encoding = null): string|false {}
4141

42-
function mb_strrichr(string $haystack, string $needle, bool $part = false, ?string $encoding = null): string|false {}
42+
function mb_strrichr(string $haystack, string $needle, bool $before_needle = false, ?string $encoding = null): string|false {}
4343

4444
function mb_substr_count(string $haystack, string $needle, ?string $encoding = null): int {}
4545

@@ -51,7 +51,7 @@ function mb_strwidth(string $string, ?string $encoding = null): int {}
5151

5252
function mb_strimwidth(string $string, int $start, int $width, string $trim_marker = "", ?string $encoding = null): string {}
5353

54-
function mb_convert_encoding(array|string $string, string $to, array|string|null $from = null): array|string|false {}
54+
function mb_convert_encoding(array|string $string, string $to_encoding, array|string|null $from_encoding = null): array|string|false {}
5555

5656
function mb_convert_case(string $string, int $mode, ?string $encoding = null): string {}
5757

@@ -65,29 +65,29 @@ function mb_list_encodings(): array {}
6565

6666
function mb_encoding_aliases(string $encoding): array {}
6767

68-
function mb_encode_mimeheader(string $string, ?string $charset = null, ?string $transfer = null, string $linefeed = "\r\n", int $indent = 0): string {}
68+
function mb_encode_mimeheader(string $string, ?string $charset = null, ?string $transfer_encoding = null, string $linefeed = "\r\n", int $indent = 0): string {}
6969

7070
function mb_decode_mimeheader(string $string): string {}
7171

72-
function mb_convert_kana(string $string, string $option = "KV", ?string $encoding = null): string {}
72+
function mb_convert_kana(string $string, string $mode = "KV", ?string $encoding = null): string {}
7373

74-
function mb_convert_variables(string $to, array|string $from, mixed &$var, mixed &...$vars): string|false {}
74+
function mb_convert_variables(string $to_encoding, array|string $from_encoding, mixed &$var, mixed &...$vars): string|false {}
7575

76-
function mb_encode_numericentity(string $string, array $convmap, ?string $encoding = null, bool $is_hex = false): string {}
76+
function mb_encode_numericentity(string $string, array $map, ?string $encoding = null, bool $use_hex = false): string {}
7777

78-
function mb_decode_numericentity(string $string, array $convmap, ?string $encoding = null): string {}
78+
function mb_decode_numericentity(string $string, array $map, ?string $encoding = null): string {}
7979

8080
function mb_send_mail(string $to, string $subject, string $message, array|string $additional_headers = [], ?string $additional_parameters = null): bool {}
8181

8282
function mb_get_info(string $type = "all"): array|string|int|false {}
8383

84-
function mb_check_encoding(array|string|null $var = null, ?string $encoding = null): bool {}
84+
function mb_check_encoding(array|string|null $value = null, ?string $encoding = null): bool {}
8585

8686
function mb_scrub(string $string, ?string $encoding = null): string {}
8787

8888
function mb_ord(string $string, ?string $encoding = null): int|false {}
8989

90-
function mb_chr(int $cp, ?string $encoding = null): string|false {}
90+
function mb_chr(int $codepoint, ?string $encoding = null): string|false {}
9191

9292
#ifdef HAVE_MBREGEX
9393
function mb_regex_encoding(?string $encoding = null): string|bool {}
@@ -98,23 +98,23 @@ function mb_ereg(string $pattern, string $string, &$registers = null): int|false
9898
/** @param array $registers */
9999
function mb_eregi(string $pattern, string $string, &$registers = null): int|false {}
100100

101-
function mb_ereg_replace(string $pattern, string $replacement, string $string, ?string $option = null): string|false|null {}
101+
function mb_ereg_replace(string $pattern, string $replacement, string $string, ?string $options = null): string|false|null {}
102102

103-
function mb_eregi_replace(string $pattern, string $replacement, string $string, ?string $option = null): string|false|null {}
103+
function mb_eregi_replace(string $pattern, string $replacement, string $string, ?string $options = null): string|false|null {}
104104

105-
function mb_ereg_replace_callback(string $pattern, callable $callback, string $string, ?string $option = null): string|false|null {}
105+
function mb_ereg_replace_callback(string $pattern, callable $callback, string $string, ?string $options = null): string|false|null {}
106106

107107
function mb_split(string $pattern, string $string, int $limit = -1): array|false {}
108108

109-
function mb_ereg_match(string $pattern, string $string, ?string $option = null): bool {}
109+
function mb_ereg_match(string $pattern, string $string, ?string $options = null): bool {}
110110

111-
function mb_ereg_search(?string $pattern = null, ?string $option = null): bool {}
111+
function mb_ereg_search(?string $pattern = null, ?string $options = null): bool {}
112112

113-
function mb_ereg_search_pos(?string $pattern = null, ?string $option = null): array|false {}
113+
function mb_ereg_search_pos(?string $pattern = null, ?string $options = null): array|false {}
114114

115-
function mb_ereg_search_regs(?string $pattern = null, ?string $option = null): array|false {}
115+
function mb_ereg_search_regs(?string $pattern = null, ?string $options = null): array|false {}
116116

117-
function mb_ereg_search_init(string $string, ?string $pattern = null, ?string $option = null): bool {}
117+
function mb_ereg_search_init(string $string, ?string $pattern = null, ?string $options = null): bool {}
118118

119119
function mb_ereg_search_getregs(): array|false {}
120120

ext/mbstring/mbstring_arginfo.h

+20-20
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/* This is a generated file, edit the .stub.php file instead.
2-
* Stub hash: 85cabf678a06175d4da073be79a0951d4f3786ed */
2+
* Stub hash: 78f2c0279d16ea58c551260b84d3504177ae4733 */
33

44
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_mb_language, 0, 0, MAY_BE_STRING|MAY_BE_BOOL)
55
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, language, IS_STRING, 1, "null")
@@ -39,7 +39,7 @@ ZEND_END_ARG_INFO()
3939

4040
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_mb_str_split, 0, 1, IS_ARRAY, 0)
4141
ZEND_ARG_TYPE_INFO(0, string, IS_STRING, 0)
42-
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, split_length, IS_LONG, 0, "1")
42+
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, length, IS_LONG, 0, "1")
4343
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, encoding, IS_STRING, 1, "null")
4444
ZEND_END_ARG_INFO()
4545

@@ -64,7 +64,7 @@ ZEND_END_ARG_INFO()
6464
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_mb_strstr, 0, 2, MAY_BE_STRING|MAY_BE_FALSE)
6565
ZEND_ARG_TYPE_INFO(0, haystack, IS_STRING, 0)
6666
ZEND_ARG_TYPE_INFO(0, needle, IS_STRING, 0)
67-
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, part, _IS_BOOL, 0, "false")
67+
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, before_needle, _IS_BOOL, 0, "false")
6868
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, encoding, IS_STRING, 1, "null")
6969
ZEND_END_ARG_INFO()
7070

@@ -101,8 +101,8 @@ ZEND_END_ARG_INFO()
101101

102102
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_mb_convert_encoding, 0, 2, MAY_BE_ARRAY|MAY_BE_STRING|MAY_BE_FALSE)
103103
ZEND_ARG_TYPE_MASK(0, string, MAY_BE_ARRAY|MAY_BE_STRING, NULL)
104-
ZEND_ARG_TYPE_INFO(0, to, IS_STRING, 0)
105-
ZEND_ARG_TYPE_MASK(0, from, MAY_BE_ARRAY|MAY_BE_STRING|MAY_BE_NULL, "null")
104+
ZEND_ARG_TYPE_INFO(0, to_encoding, IS_STRING, 0)
105+
ZEND_ARG_TYPE_MASK(0, from_encoding, MAY_BE_ARRAY|MAY_BE_STRING|MAY_BE_NULL, "null")
106106
ZEND_END_ARG_INFO()
107107

108108
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_mb_convert_case, 0, 2, IS_STRING, 0)
@@ -134,7 +134,7 @@ ZEND_END_ARG_INFO()
134134
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_mb_encode_mimeheader, 0, 1, IS_STRING, 0)
135135
ZEND_ARG_TYPE_INFO(0, string, IS_STRING, 0)
136136
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, charset, IS_STRING, 1, "null")
137-
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, transfer, IS_STRING, 1, "null")
137+
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, transfer_encoding, IS_STRING, 1, "null")
138138
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, linefeed, IS_STRING, 0, "\"\\r\\n\"")
139139
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, indent, IS_LONG, 0, "0")
140140
ZEND_END_ARG_INFO()
@@ -145,27 +145,27 @@ ZEND_END_ARG_INFO()
145145

146146
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_mb_convert_kana, 0, 1, IS_STRING, 0)
147147
ZEND_ARG_TYPE_INFO(0, string, IS_STRING, 0)
148-
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, option, IS_STRING, 0, "\"KV\"")
148+
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, mode, IS_STRING, 0, "\"KV\"")
149149
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, encoding, IS_STRING, 1, "null")
150150
ZEND_END_ARG_INFO()
151151

152152
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_mb_convert_variables, 0, 3, MAY_BE_STRING|MAY_BE_FALSE)
153-
ZEND_ARG_TYPE_INFO(0, to, IS_STRING, 0)
154-
ZEND_ARG_TYPE_MASK(0, from, MAY_BE_ARRAY|MAY_BE_STRING, NULL)
153+
ZEND_ARG_TYPE_INFO(0, to_encoding, IS_STRING, 0)
154+
ZEND_ARG_TYPE_MASK(0, from_encoding, MAY_BE_ARRAY|MAY_BE_STRING, NULL)
155155
ZEND_ARG_TYPE_INFO(1, var, IS_MIXED, 0)
156156
ZEND_ARG_VARIADIC_TYPE_INFO(1, vars, IS_MIXED, 0)
157157
ZEND_END_ARG_INFO()
158158

159159
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_mb_encode_numericentity, 0, 2, IS_STRING, 0)
160160
ZEND_ARG_TYPE_INFO(0, string, IS_STRING, 0)
161-
ZEND_ARG_TYPE_INFO(0, convmap, IS_ARRAY, 0)
161+
ZEND_ARG_TYPE_INFO(0, map, IS_ARRAY, 0)
162162
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, encoding, IS_STRING, 1, "null")
163-
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, is_hex, _IS_BOOL, 0, "false")
163+
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, use_hex, _IS_BOOL, 0, "false")
164164
ZEND_END_ARG_INFO()
165165

166166
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_mb_decode_numericentity, 0, 2, IS_STRING, 0)
167167
ZEND_ARG_TYPE_INFO(0, string, IS_STRING, 0)
168-
ZEND_ARG_TYPE_INFO(0, convmap, IS_ARRAY, 0)
168+
ZEND_ARG_TYPE_INFO(0, map, IS_ARRAY, 0)
169169
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, encoding, IS_STRING, 1, "null")
170170
ZEND_END_ARG_INFO()
171171

@@ -182,7 +182,7 @@ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_mb_get_info, 0, 0, MAY_BE_ARRAY|
182182
ZEND_END_ARG_INFO()
183183

184184
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_mb_check_encoding, 0, 0, _IS_BOOL, 0)
185-
ZEND_ARG_TYPE_MASK(0, var, MAY_BE_ARRAY|MAY_BE_STRING|MAY_BE_NULL, "null")
185+
ZEND_ARG_TYPE_MASK(0, value, MAY_BE_ARRAY|MAY_BE_STRING|MAY_BE_NULL, "null")
186186
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, encoding, IS_STRING, 1, "null")
187187
ZEND_END_ARG_INFO()
188188

@@ -194,7 +194,7 @@ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_mb_ord, 0, 1, MAY_BE_LONG|MAY_BE
194194
ZEND_END_ARG_INFO()
195195

196196
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_mb_chr, 0, 1, MAY_BE_STRING|MAY_BE_FALSE)
197-
ZEND_ARG_TYPE_INFO(0, cp, IS_LONG, 0)
197+
ZEND_ARG_TYPE_INFO(0, codepoint, IS_LONG, 0)
198198
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, encoding, IS_STRING, 1, "null")
199199
ZEND_END_ARG_INFO()
200200

@@ -221,7 +221,7 @@ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_mb_ereg_replace, 0, 3, MAY_BE_ST
221221
ZEND_ARG_TYPE_INFO(0, pattern, IS_STRING, 0)
222222
ZEND_ARG_TYPE_INFO(0, replacement, IS_STRING, 0)
223223
ZEND_ARG_TYPE_INFO(0, string, IS_STRING, 0)
224-
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, option, IS_STRING, 1, "null")
224+
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, options, IS_STRING, 1, "null")
225225
ZEND_END_ARG_INFO()
226226
#endif
227227

@@ -234,7 +234,7 @@ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_mb_ereg_replace_callback, 0, 3,
234234
ZEND_ARG_TYPE_INFO(0, pattern, IS_STRING, 0)
235235
ZEND_ARG_TYPE_INFO(0, callback, IS_CALLABLE, 0)
236236
ZEND_ARG_TYPE_INFO(0, string, IS_STRING, 0)
237-
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, option, IS_STRING, 1, "null")
237+
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, options, IS_STRING, 1, "null")
238238
ZEND_END_ARG_INFO()
239239
#endif
240240

@@ -250,21 +250,21 @@ ZEND_END_ARG_INFO()
250250
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_mb_ereg_match, 0, 2, _IS_BOOL, 0)
251251
ZEND_ARG_TYPE_INFO(0, pattern, IS_STRING, 0)
252252
ZEND_ARG_TYPE_INFO(0, string, IS_STRING, 0)
253-
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, option, IS_STRING, 1, "null")
253+
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, options, IS_STRING, 1, "null")
254254
ZEND_END_ARG_INFO()
255255
#endif
256256

257257
#if defined(HAVE_MBREGEX)
258258
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_mb_ereg_search, 0, 0, _IS_BOOL, 0)
259259
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, pattern, IS_STRING, 1, "null")
260-
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, option, IS_STRING, 1, "null")
260+
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, options, IS_STRING, 1, "null")
261261
ZEND_END_ARG_INFO()
262262
#endif
263263

264264
#if defined(HAVE_MBREGEX)
265265
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_mb_ereg_search_pos, 0, 0, MAY_BE_ARRAY|MAY_BE_FALSE)
266266
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, pattern, IS_STRING, 1, "null")
267-
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, option, IS_STRING, 1, "null")
267+
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, options, IS_STRING, 1, "null")
268268
ZEND_END_ARG_INFO()
269269
#endif
270270

@@ -276,7 +276,7 @@ ZEND_END_ARG_INFO()
276276
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_mb_ereg_search_init, 0, 1, _IS_BOOL, 0)
277277
ZEND_ARG_TYPE_INFO(0, string, IS_STRING, 0)
278278
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, pattern, IS_STRING, 1, "null")
279-
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, option, IS_STRING, 1, "null")
279+
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, options, IS_STRING, 1, "null")
280280
ZEND_END_ARG_INFO()
281281
#endif
282282

ext/mbstring/tests/bug79149.phpt

+3-3
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ try {
2424

2525
?>
2626
--EXPECTF--
27-
mb_convert_encoding(): Argument #3 ($from) contains invalid encoding "0"
27+
mb_convert_encoding(): Argument #3 ($from_encoding) contains invalid encoding "0"
2828

2929
Warning: Array to string conversion in %s on line %d
30-
mb_convert_encoding(): Argument #3 ($from) contains invalid encoding "Array"
31-
mb_convert_encoding(): Argument #3 ($from) contains invalid encoding "foo"
30+
mb_convert_encoding(): Argument #3 ($from_encoding) contains invalid encoding "Array"
31+
mb_convert_encoding(): Argument #3 ($from_encoding) contains invalid encoding "foo"

ext/mbstring/tests/mb_convert_encoding.phpt

+1-1
Original file line numberDiff line numberDiff line change
@@ -124,4 +124,4 @@ JIS: GyRCRnxLXDhsJUYlLSU5JUgkRyQ5ISMbKEIwMTIzNBskQiM1IzYjNyM4IzkhIxsoQg==
124124
== INVALID PARAMETER ==
125125
INT: 1234
126126
EUC-JP:
127-
mb_convert_encoding(): Argument #2 ($to) must be a valid encoding, "BAD" given
127+
mb_convert_encoding(): Argument #2 ($to_encoding) must be a valid encoding, "BAD" given

ext/mbstring/tests/mb_convert_encoding_empty_encoding_list.phpt

+2-2
Original file line numberDiff line numberDiff line change
@@ -23,5 +23,5 @@ try {
2323

2424
?>
2525
--EXPECT--
26-
mb_convert_encoding(): Argument #3 ($from) must specify at least one encoding
27-
mb_convert_encoding(): Argument #3 ($from) must specify at least one encoding
26+
mb_convert_encoding(): Argument #3 ($from_encoding) must specify at least one encoding
27+
mb_convert_encoding(): Argument #3 ($from_encoding) must specify at least one encoding

ext/mbstring/tests/mb_convert_variables_empty_encoding_list.phpt

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,5 +22,5 @@ try {
2222

2323
?>
2424
--EXPECT--
25-
mb_convert_variables(): Argument #2 ($from) must specify at least one encoding
26-
mb_convert_variables(): Argument #2 ($from) must specify at least one encoding
25+
mb_convert_variables(): Argument #2 ($from_encoding) must specify at least one encoding
26+
mb_convert_variables(): Argument #2 ($from_encoding) must specify at least one encoding

ext/mbstring/tests/mb_decode_numericentity.phpt

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,4 +49,4 @@ aŒbœcŠdše€fg
4949
&#0000000000
5050
&#000000000
5151
föo
52-
mb_decode_numericentity(): Argument #2 ($convmap) must have a multiple of 4 elements
52+
mb_decode_numericentity(): Argument #2 ($map) must have a multiple of 4 elements

ext/mbstring/tests/mb_encode_numericentity.phpt

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,4 @@ try {
3131
ƒΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩαβγδεζηθικλμνξοπρςστυφχψωϑϒϖ•…′″‾⁄℘ℑℜ™ℵ←↑→↓↔↵⇐⇑⇒⇓⇔∀∂∃∅∇∈∉∋∏∑−∗√∝∞∠∧∨∩∪∫∴∼≅≈≠≡≤≥⊂⊃⊄⊆⊇⊕⊗⊥⋅⌈⌉⌊⌋〈〉◊♠♣♥♦
3232
aŒbœcŠdše€fg
3333
föo
34-
mb_encode_numericentity(): Argument #2 ($convmap) must have a multiple of 4 elements
34+
mb_encode_numericentity(): Argument #2 ($map) must have a multiple of 4 elements

ext/mbstring/tests/mb_str_split_error_conditions.phpt

+2-2
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,6 @@ try {
2828

2929
?>
3030
--EXPECT--
31-
mb_str_split(): Argument #2 ($split_length) must be greater than 0
32-
mb_str_split(): Argument #2 ($split_length) must be greater than 0
31+
mb_str_split(): Argument #2 ($length) must be greater than 0
32+
mb_str_split(): Argument #2 ($length) must be greater than 0
3333
mb_str_split(): Argument #3 ($encoding) must be a valid encoding, "BAD_ENCODING" given

ext/mbstring/tests/mb_str_unknown_encoding.phpt

+1-1
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ try {
144144
--EXPECT--
145145
mb_chr(): Argument #2 ($encoding) must be a valid encoding, "UTF-0" given
146146
mb_convert_case(): Argument #3 ($encoding) must be a valid encoding, "UTF-0" given
147-
mb_convert_encoding(): Argument #3 ($from) contains invalid encoding "UTF-0"
147+
mb_convert_encoding(): Argument #3 ($from_encoding) contains invalid encoding "UTF-0"
148148
mb_convert_kana(): Argument #3 ($encoding) must be a valid encoding, "UTF-0" given
149149
mb_decode_numericentity(): Argument #3 ($encoding) must be a valid encoding, "UTF-0" given
150150
mb_ord(): Argument #2 ($encoding) must be a valid encoding, "UTF-0" given

ext/standard/basic_functions.stub.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -683,7 +683,7 @@ function str_shuffle(string $str): string {}
683683

684684
function str_word_count(string $str, int $format = 0, ?string $charlist = null): array|int {}
685685

686-
function str_split(string $str, int $split_length = 1): array {}
686+
function str_split(string $str, int $length = 1): array {}
687687

688688
function strpbrk(string $haystack, string $char_list): string|false {}
689689

ext/standard/basic_functions_arginfo.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/* This is a generated file, edit the .stub.php file instead.
2-
* Stub hash: 5275c2ba801f36ecf17e6b615b19373aca34e852 */
2+
* Stub hash: 2c07afb4d5c9c63d99b5f709bca9ea37c8b9073d */
33

44
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_set_time_limit, 0, 1, _IS_BOOL, 0)
55
ZEND_ARG_TYPE_INFO(0, seconds, IS_LONG, 0)
@@ -1074,7 +1074,7 @@ ZEND_END_ARG_INFO()
10741074

10751075
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_str_split, 0, 1, IS_ARRAY, 0)
10761076
ZEND_ARG_TYPE_INFO(0, str, IS_STRING, 0)
1077-
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, split_length, IS_LONG, 0, "1")
1077+
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, length, IS_LONG, 0, "1")
10781078
ZEND_END_ARG_INFO()
10791079

10801080
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_strpbrk, 0, 2, MAY_BE_STRING|MAY_BE_FALSE)

ext/standard/tests/strings/str_split_variation6.phpt

+3-3
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ for($count = 0; $count < count($values); $count++) {
3535
--EXPECT--
3636
*** Testing str_split() : different integer values for 'split_length' ***
3737
-- Iteration 1 --
38-
str_split(): Argument #2 ($split_length) must be greater than 0
38+
str_split(): Argument #2 ($length) must be greater than 0
3939
-- Iteration 2 --
4040
array(42) {
4141
[0]=>
@@ -124,7 +124,7 @@ array(42) {
124124
string(1) "t"
125125
}
126126
-- Iteration 3 --
127-
str_split(): Argument #2 ($split_length) must be greater than 0
127+
str_split(): Argument #2 ($length) must be greater than 0
128128
-- Iteration 4 --
129129
array(1) {
130130
[0]=>
@@ -143,4 +143,4 @@ array(1) {
143143
string(42) "This is a string with 123 & escape char \t"
144144
}
145145
-- Iteration 7 --
146-
str_split(): Argument #2 ($split_length) must be greater than 0
146+
str_split(): Argument #2 ($length) must be greater than 0

0 commit comments

Comments
 (0)