Skip to content

Commit 6234f96

Browse files
committed
Use F1 instead of FN where possible
1 parent 2342155 commit 6234f96

File tree

7 files changed

+56
-28
lines changed

7 files changed

+56
-28
lines changed

Zend/Optimizer/zend_func_infos.h

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -157,10 +157,10 @@ static const func_info_t func_infos[] = {
157157
#if defined(HAVE_BIND_TEXTDOMAIN_CODESET)
158158
F1("bind_textdomain_codeset", MAY_BE_STRING|MAY_BE_FALSE),
159159
#endif
160-
FN("gmp_div_qr", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_OBJECT),
161-
FN("gmp_sqrtrem", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_OBJECT),
162-
FN("gmp_rootrem", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_OBJECT),
163-
FN("gmp_gcdext", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_STRING|MAY_BE_ARRAY_OF_OBJECT),
160+
F1("gmp_div_qr", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_OBJECT),
161+
F1("gmp_sqrtrem", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_OBJECT),
162+
F1("gmp_rootrem", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_OBJECT),
163+
F1("gmp_gcdext", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_STRING|MAY_BE_ARRAY_OF_OBJECT),
164164
F1("hash", MAY_BE_STRING|MAY_BE_FALSE),
165165
F1("hash_file", MAY_BE_STRING|MAY_BE_FALSE),
166166
F1("hash_hmac", MAY_BE_STRING|MAY_BE_FALSE),
@@ -187,13 +187,13 @@ static const func_info_t func_infos[] = {
187187
F1("iconv_mime_decode_headers", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_STRING|MAY_BE_ARRAY_OF_STRING|MAY_BE_ARRAY_OF_ARRAY|MAY_BE_FALSE),
188188
F1("iconv", MAY_BE_STRING|MAY_BE_FALSE),
189189
F1("iconv_get_encoding", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_STRING|MAY_BE_ARRAY_OF_STRING|MAY_BE_STRING|MAY_BE_FALSE),
190-
FN("intlcal_get_available_locales", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_STRING),
191-
FN("datefmt_localtime", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_STRING|MAY_BE_ARRAY_OF_LONG|MAY_BE_FALSE),
192-
FN("locale_get_keywords", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_STRING|MAY_BE_ARRAY_OF_STRING|MAY_BE_FALSE|MAY_BE_NULL),
193-
FN("msgfmt_parse", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_LONG|MAY_BE_ARRAY_OF_DOUBLE|MAY_BE_ARRAY_OF_STRING|MAY_BE_FALSE),
194-
FN("msgfmt_parse_message", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_LONG|MAY_BE_ARRAY_OF_DOUBLE|MAY_BE_ARRAY_OF_STRING|MAY_BE_FALSE),
195-
FN("resourcebundle_locales", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_STRING|MAY_BE_FALSE),
196-
FN("transliterator_list_ids", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_STRING|MAY_BE_FALSE),
190+
F1("intlcal_get_available_locales", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_STRING),
191+
F1("datefmt_localtime", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_STRING|MAY_BE_ARRAY_OF_LONG|MAY_BE_FALSE),
192+
F1("locale_get_keywords", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_STRING|MAY_BE_ARRAY_OF_STRING|MAY_BE_FALSE|MAY_BE_NULL),
193+
F1("msgfmt_parse", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_LONG|MAY_BE_ARRAY_OF_DOUBLE|MAY_BE_ARRAY_OF_STRING|MAY_BE_FALSE),
194+
F1("msgfmt_parse_message", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_LONG|MAY_BE_ARRAY_OF_DOUBLE|MAY_BE_ARRAY_OF_STRING|MAY_BE_FALSE),
195+
F1("resourcebundle_locales", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_STRING|MAY_BE_FALSE),
196+
F1("transliterator_list_ids", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_OF_STRING|MAY_BE_FALSE),
197197
F1("json_encode", MAY_BE_STRING|MAY_BE_FALSE),
198198
F1("json_last_error_msg", MAY_BE_STRING),
199199
F1("ldap_get_entries", MAY_BE_ARRAY|MAY_BE_ARRAY_KEY_LONG|MAY_BE_ARRAY_KEY_STRING|MAY_BE_ARRAY_OF_LONG|MAY_BE_ARRAY_OF_ARRAY|MAY_BE_FALSE),

ext/gmp/gmp.stub.php

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,10 @@ function gmp_sub(GMP|int|string $num1, GMP|int|string $num2): GMP {}
2222

2323
function gmp_mul(GMP|int|string $num1, GMP|int|string $num2): GMP {}
2424

25-
/** @return array<int, GMP> */
25+
/**
26+
* @return array<int, GMP>
27+
* @refcount 1
28+
*/
2629
function gmp_div_qr(GMP|int|string $num1, GMP|int|string $num2, int $rounding_mode = GMP_ROUND_ZERO): array {}
2730

2831
function gmp_div_q(GMP|int|string $num1, GMP|int|string $num2, int $rounding_mode = GMP_ROUND_ZERO): GMP {}
@@ -44,12 +47,18 @@ function gmp_fact(GMP|int|string $num): GMP {}
4447

4548
function gmp_sqrt(GMP|int|string $num): GMP {}
4649

47-
/** @return array<int, GMP> */
50+
/**
51+
* @return array<int, GMP>
52+
* @refcount 1
53+
*/
4854
function gmp_sqrtrem(GMP|int|string $num): array {}
4955

5056
function gmp_root(GMP|int|string $num, int $nth): GMP {}
5157

52-
/** @return array<int, GMP> */
58+
/**
59+
* @return array<int, GMP>
60+
* @refcount 1
61+
*/
5362
function gmp_rootrem(GMP|int|string $num, int $nth): array {}
5463

5564
function gmp_pow(GMP|int|string $num, int $exponent): GMP {}
@@ -64,7 +73,10 @@ function gmp_prob_prime(GMP|int|string $num, int $repetitions = 10): int {}
6473

6574
function gmp_gcd(GMP|int|string $num1, GMP|int|string $num2): GMP {}
6675

67-
/** @return array<string, GMP> */
76+
/**
77+
* @return array<string, GMP>
78+
* @refcount 1
79+
*/
6880
function gmp_gcdext(GMP|int|string $num1, GMP|int|string $num2): array {}
6981

7082
function gmp_lcm(GMP|int|string $num1, GMP|int|string $num2): GMP {}

ext/gmp/gmp_arginfo.h

Lines changed: 1 addition & 1 deletion
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: 7e2458ac4958923dfd43bde52cb111dd1c59f032 */
2+
* Stub hash: 05e618ec428bd8769410153469c42cbc923ea77f */
33

44
ZEND_BEGIN_ARG_WITH_RETURN_OBJ_INFO_EX(arginfo_gmp_init, 0, 1, GMP, 0)
55
ZEND_ARG_TYPE_MASK(0, num, MAY_BE_LONG|MAY_BE_STRING, NULL)

ext/intl/php_intl.stub.php

Lines changed: 25 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,10 @@ function intlcal_get_keyword_values_for_locale(string $keyword, string $locale,
1515

1616
function intlcal_get_now(): float {}
1717

18-
/** @return array<int, string> */
18+
/**
19+
* @return array<int, string>
20+
* @refcount 1
21+
*/
1922
function intlcal_get_available_locales(): array {}
2023

2124
function intlcal_get(IntlCalendar $calendar, int $field): int|false {}
@@ -210,6 +213,7 @@ function datefmt_parse(IntlDateFormatter $formatter, string $string, &$offset =
210213
/**
211214
* @param int $offset
212215
* @return array<string, int>|false
216+
* @refcount 1
213217
*/
214218
function datefmt_localtime(IntlDateFormatter $formatter, string $string, &$offset = null): array|false {}
215219

@@ -298,7 +302,10 @@ function locale_get_script(string $locale): ?string {}
298302

299303
function locale_get_region(string $locale): ?string {}
300304

301-
/** @return array<string, string>|false|null */
305+
/**
306+
* @return array<string, string>|false|null
307+
* @refcount 1
308+
*/
302309
function locale_get_keywords(string $locale): array|false|null {}
303310

304311
function locale_get_display_script(string $locale, ?string $displayLocale = null): string|false {}
@@ -333,10 +340,16 @@ function msgfmt_format(MessageFormatter $formatter, array $values): string|false
333340

334341
function msgfmt_format_message(string $locale, string $pattern, array $values): string|false {}
335342

336-
/** @return array<int, int|float|string>|false */
343+
/**
344+
* @return array<int, int|float|string>|false
345+
* @refcount 1
346+
*/
337347
function msgfmt_parse(MessageFormatter $formatter, string $string): array|false {}
338348

339-
/** @return array<int, int|float|string>|false */
349+
/**
350+
* @return array<int, int|float|string>|false
351+
* @refcount 1
352+
*/
340353
function msgfmt_parse_message(string $locale, string $pattern, string $message): array|false {}
341354

342355
function msgfmt_set_pattern(MessageFormatter $formatter, string $pattern): bool {}
@@ -368,7 +381,10 @@ function resourcebundle_get(ResourceBundle $bundle, $index, bool $fallback = tru
368381

369382
function resourcebundle_count(ResourceBundle $bundle): int {}
370383

371-
/** @return array<int, string>|false */
384+
/**
385+
* @return array<int, string>|false
386+
* @refcount 1
387+
*/
372388
function resourcebundle_locales(string $bundle): array|false {}
373389

374390
function resourcebundle_get_error_code(ResourceBundle $bundle): int {}
@@ -439,7 +455,10 @@ function transliterator_create(string $id, int $direction = Transliterator::FORW
439455

440456
function transliterator_create_from_rules(string $rules, int $direction = Transliterator::FORWARD): ?Transliterator {}
441457

442-
/** @return array<int, string>|false */
458+
/**
459+
* @return array<int, string>|false
460+
* @refcount 1
461+
*/
443462
function transliterator_list_ids(): array|false {}
444463

445464
function transliterator_create_inverse(Transliterator $transliterator): ?Transliterator {}

ext/intl/php_intl_arginfo.h

Lines changed: 1 addition & 1 deletion
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: 05a78c68f7bc5156cccecf4a8088bf8e3f4fdb4f */
2+
* Stub hash: 09aa0aa66c78b86c0e6e0e554c3ebe205a0e5f59 */
33

44
ZEND_BEGIN_ARG_WITH_RETURN_OBJ_INFO_EX(arginfo_intlcal_create_instance, 0, 0, IntlCalendar, 1)
55
ZEND_ARG_INFO_WITH_DEFAULT_VALUE(0, timezone, "null")

ext/intl/uchar/uchar.stub.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -84,10 +84,7 @@ public static function getPropertyValueEnum(int $property, string $name): int {}
8484
/** @tentative-return-type */
8585
public static function getPropertyValueName(int $property, int $value, int $type = IntlChar::LONG_PROPERTY_NAME): string|false {}
8686

87-
/**
88-
* @return array<int, int>
89-
* @tentative-return-type
90-
*/
87+
/** @tentative-return-type */
9188
public static function getUnicodeVersion(): array {}
9289

9390
/** @tentative-return-type */

ext/intl/uchar/uchar_arginfo.h

Lines changed: 1 addition & 1 deletion
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: 8ec0d325c5108a66b45a5749591b685f22cac454 */
2+
* Stub hash: 2b8605be915f05929dc0ade2edfb6f6ab942218c */
33

44
ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_IntlChar_hasBinaryProperty, 0, 2, _IS_BOOL, 1)
55
ZEND_ARG_TYPE_MASK(0, codepoint, MAY_BE_LONG|MAY_BE_STRING, NULL)

0 commit comments

Comments
 (0)