Skip to content

Commit 02f2056

Browse files
TysonAndrenikic
authored andcommitted
Update zend_func_info for pcre/curl/iconv/json
preg_quote and curl_error now have a non-null return type of `string`. zend_func_info now duplicates many real reflection types (some of which are now non-null) Closes GH-4788.
1 parent 52dfe87 commit 02f2056

File tree

1 file changed

+2
-17
lines changed

1 file changed

+2
-17
lines changed

ext/opcache/Optimizer/zend_func_info.c

Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -669,9 +669,8 @@ static const func_info_t func_infos[] = {
669669
FN("preg_replace_callback", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_STRING | MAY_BE_ARRAY | MAY_BE_ARRAY_KEY_ANY | MAY_BE_ARRAY_OF_STRING),
670670
F1("preg_filter", MAY_BE_FALSE | MAY_BE_STRING | MAY_BE_ARRAY | MAY_BE_ARRAY_KEY_ANY | MAY_BE_ARRAY_OF_STRING),
671671
F1("preg_split", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_ARRAY | MAY_BE_ARRAY_KEY_LONG | MAY_BE_ARRAY_OF_STRING | MAY_BE_ARRAY_OF_ARRAY),
672-
FN("preg_quote", MAY_BE_NULL | MAY_BE_STRING),
672+
FN("preg_quote", MAY_BE_STRING),
673673
F1("preg_grep", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_ARRAY | MAY_BE_ARRAY_KEY_ANY | MAY_BE_ARRAY_OF_REF | MAY_BE_ARRAY_OF_ANY),
674-
F0("preg_last_error", MAY_BE_NULL | MAY_BE_LONG),
675674

676675
/* ext/mysqli */
677676
F1("mysqli_connect", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_OBJECT),
@@ -778,31 +777,19 @@ static const func_info_t func_infos[] = {
778777
F1("curl_init", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_RESOURCE),
779778
F1("curl_copy_handle", MAY_BE_NULL | MAY_BE_RESOURCE),
780779
F1("curl_version", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_ARRAY | MAY_BE_ARRAY_KEY_STRING | MAY_BE_ARRAY_OF_LONG | MAY_BE_ARRAY_OF_STRING | MAY_BE_ARRAY_OF_ARRAY),
781-
F0("curl_setopt", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_TRUE),
782-
F0("curl_setopt_array", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_TRUE),
783780
FN("curl_exec", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_STRING),
784781
F1("curl_getinfo", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_STRING | MAY_BE_LONG | MAY_BE_DOUBLE | MAY_BE_ARRAY | MAY_BE_ARRAY_KEY_ANY | MAY_BE_ARRAY_OF_ANY),
785-
F1("curl_error", MAY_BE_NULL | MAY_BE_STRING),
786-
F0("curl_errno", MAY_BE_NULL | MAY_BE_LONG),
787-
F0("curl_close", MAY_BE_NULL),
782+
F1("curl_error", MAY_BE_STRING),
788783
F1("curl_strerror", MAY_BE_NULL | MAY_BE_STRING),
789784
F1("curl_multi_strerror", MAY_BE_NULL | MAY_BE_STRING),
790-
F0("curl_reset", MAY_BE_NULL),
791785
F1("curl_escape", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_STRING),
792786
F1("curl_unescape", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_STRING),
793-
F0("curl_pause", MAY_BE_NULL | MAY_BE_LONG),
794787
F1("curl_multi_init", MAY_BE_RESOURCE),
795-
F0("curl_multi_add_handle", MAY_BE_NULL | MAY_BE_LONG),
796-
F0("curl_multi_remove_handle", MAY_BE_NULL | MAY_BE_LONG),
797-
F0("curl_multi_select", MAY_BE_NULL | MAY_BE_LONG),
798-
F0("curl_multi_exec", MAY_BE_NULL | MAY_BE_LONG),
799788
FN("curl_multi_getcontent", MAY_BE_NULL | MAY_BE_STRING),
800789
F1("curl_multi_info_read", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_LONG | MAY_BE_ARRAY | MAY_BE_ARRAY_KEY_STRING | MAY_BE_ARRAY_OF_LONG | MAY_BE_ARRAY_OF_RESOURCE),
801790
F0("curl_multi_close", MAY_BE_NULL | MAY_BE_FALSE),
802791
F0("curl_multi_setopt", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_TRUE),
803792
F1("curl_share_init", MAY_BE_RESOURCE),
804-
F0("curl_share_close", MAY_BE_NULL),
805-
F0("curl_share_setopt", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_TRUE),
806793
F1("curl_file_create", MAY_BE_OBJECT),
807794

808795
/* ext/mbstring */
@@ -866,7 +853,6 @@ static const func_info_t func_infos[] = {
866853
/* ext/iconv */
867854
F1("iconv", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_STRING),
868855
F1("iconv_get_encoding", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_STRING | MAY_BE_ARRAY | MAY_BE_ARRAY_KEY_STRING | MAY_BE_ARRAY_OF_STRING),
869-
F0("iconv_set_encoding", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_TRUE),
870856
F0("iconv_strlen", MAY_BE_FALSE | MAY_BE_LONG),
871857
F1("iconv_substr", MAY_BE_FALSE | MAY_BE_STRING),
872858
F0("iconv_strpos", MAY_BE_FALSE | MAY_BE_LONG),
@@ -878,7 +864,6 @@ static const func_info_t func_infos[] = {
878864
/* ext/json */
879865
F1("json_encode", MAY_BE_NULL | MAY_BE_FALSE | MAY_BE_STRING),
880866
F1("json_decode", MAY_BE_ANY | MAY_BE_ARRAY_KEY_ANY | MAY_BE_ARRAY_OF_ANY),
881-
F0("json_last_error", MAY_BE_LONG),
882867
F1("json_last_error_msg", MAY_BE_STRING),
883868

884869
/* ext/xml */

0 commit comments

Comments
 (0)