From: Xinchen Hui Date: Sun, 13 Dec 2015 06:52:37 +0000 (-0800) Subject: Internal function argumensts cleanup (strict_types) X-Git-Tag: php-7.0.2RC1~23 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=4171a8f6c631e3c34d1d070d553e7611b5474263;p=php Internal function argumensts cleanup (strict_types) --- diff --git a/ext/com_dotnet/com_com.c b/ext/com_dotnet/com_com.c index fc7a04000d..121433688d 100644 --- a/ext/com_dotnet/com_com.c +++ b/ext/com_dotnet/com_com.c @@ -810,7 +810,7 @@ PHP_FUNCTION(com_message_pump) } /* }}} */ -/* {{{ proto bool com_load_typelib(string typelib_name [, int case_insensitive]) +/* {{{ proto bool com_load_typelib(string typelib_name [, bool case_insensitive]) Loads a Typelibrary and registers its constants */ PHP_FUNCTION(com_load_typelib) { diff --git a/ext/date/php_date.c b/ext/date/php_date.c index 50c48eb439..828f5e5ef7 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -3579,9 +3579,9 @@ PHP_FUNCTION(date_diff) zval *object1, *object2; php_date_obj *dateobj1, *dateobj2; php_interval_obj *interval; - zend_long absolute = 0; + zend_bool absolute = 0; - if (zend_parse_method_parameters(ZEND_NUM_ARGS(), getThis(), "OO|l", &object1, date_ce_interface, &object2, date_ce_interface, &absolute) == FAILURE) { + if (zend_parse_method_parameters(ZEND_NUM_ARGS(), getThis(), "OO|b", &object1, date_ce_interface, &object2, date_ce_interface, &absolute) == FAILURE) { RETURN_FALSE; } dateobj1 = Z_PHPDATE_P(object1); diff --git a/ext/dom/node.c b/ext/dom/node.c index 2f35e0110b..cf119f7a48 100644 --- a/ext/dom/node.c +++ b/ext/dom/node.c @@ -1348,9 +1348,9 @@ PHP_FUNCTION(dom_node_clone_node) xmlNode *n, *node; int ret; dom_object *intern; - zend_long recursive = 0; + zend_bool recursive = 0; - if (zend_parse_method_parameters(ZEND_NUM_ARGS(), getThis(), "O|l", &id, dom_node_class_entry, &recursive) == FAILURE) { + if (zend_parse_method_parameters(ZEND_NUM_ARGS(), getThis(), "O|b", &id, dom_node_class_entry, &recursive) == FAILURE) { return; } diff --git a/ext/standard/streamsfuncs.c b/ext/standard/streamsfuncs.c index eb85bd0184..f257ef85e6 100644 --- a/ext/standard/streamsfuncs.c +++ b/ext/standard/streamsfuncs.c @@ -1330,7 +1330,7 @@ PHP_FUNCTION(stream_get_line) /* }}} */ -/* {{{ proto bool stream_set_blocking(resource socket, int mode) +/* {{{ proto bool stream_set_blocking(resource socket, bool mode) Set blocking/non-blocking mode on a socket or stream */ PHP_FUNCTION(stream_set_blocking) { diff --git a/ext/xml/xml.c b/ext/xml/xml.c index bcded6203a..3a300c8e7e 100644 --- a/ext/xml/xml.c +++ b/ext/xml/xml.c @@ -1383,7 +1383,7 @@ PHP_FUNCTION(xml_set_end_namespace_decl_handler) } /* }}} */ -/* {{{ proto int xml_parse(resource parser, string data [, int isFinal]) +/* {{{ proto int xml_parse(resource parser, string data [, bool isFinal]) Start parsing an XML document */ PHP_FUNCTION(xml_parse) { @@ -1392,9 +1392,9 @@ PHP_FUNCTION(xml_parse) char *data; size_t data_len; int ret; - zend_long isFinal = 0; + zend_bool isFinal = 0; - if (zend_parse_parameters(ZEND_NUM_ARGS(), "rs|l", &pind, &data, &data_len, &isFinal) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS(), "rs|b", &pind, &data, &data_len, &isFinal) == FAILURE) { return; } diff --git a/ext/xmlwriter/php_xmlwriter.c b/ext/xmlwriter/php_xmlwriter.c index a7da0e7902..9e9e8f39e8 100644 --- a/ext/xmlwriter/php_xmlwriter.c +++ b/ext/xmlwriter/php_xmlwriter.c @@ -1622,7 +1622,7 @@ static PHP_FUNCTION(xmlwriter_end_dtd_entity) } /* }}} */ -/* {{{ proto bool xmlwriter_write_dtd_entity(resource xmlwriter, string name, string content [, int pe [, string pubid [, string sysid [, string ndataid]]]]) +/* {{{ proto bool xmlwriter_write_dtd_entity(resource xmlwriter, string name, string content [, bool pe [, string pubid [, string sysid [, string ndataid]]]]) Write full DTD Entity tag - returns FALSE on error */ static PHP_FUNCTION(xmlwriter_write_dtd_entity) {