X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;f=src%2Fphp_pq_misc.c;h=df07591570153603be6137d5ec62634abc15ecda;hb=b71a5226c19caba947c99500385023fd043f6999;hp=eb1ca97cdae75a4d3ef8df9e68f2063bb2dba604;hpb=c753ebfed3a4b21409cfa46212fd2c55227c809f;p=m6w6%2Fext-pq diff --git a/src/php_pq_misc.c b/src/php_pq_misc.c index eb1ca97..df07591 100644 --- a/src/php_pq_misc.c +++ b/src/php_pq_misc.c @@ -24,8 +24,8 @@ #include "php_pq.h" #include "php_pqexc.h" -#include "php_pqconn_event.h" #include "php_pq_misc.h" +#include "php_pqconn_event.h" #undef PHP_PQ_TYPE #include "php_pq_type.h" @@ -139,7 +139,11 @@ static PHP_METHOD(pqdt, __toString) ZEND_BEGIN_ARG_INFO_EX(ai_pqdt_create_from_format, 0, 0, 2) ZEND_ARG_INFO(0, format) ZEND_ARG_INFO(0, datetime) +#if PHP_VERSION_ID >= 70200 + ZEND_ARG_OBJ_INFO(0, object, DateTimeZone, 1) +#else ZEND_ARG_INFO(0, timezone) +#endif ZEND_END_ARG_INFO(); static PHP_METHOD(pqdt, createFromFormat) { @@ -363,7 +367,7 @@ static ZEND_RESULT_CODE parse_element(ArrayParserState *a, char delim) static ZEND_RESULT_CODE parse_elements(ArrayParserState *a) { - char delims[] = {'}', PHP_PQ_DELIM_OF_ARRAY(a->typ), 0}; + char delims[] = {'}', (char) PHP_PQ_DELIM_OF_ARRAY(a->typ), 0}; while (SUCCESS == parse_element(a, delims[1])) { switch (caa(a, delims, 0)) {