Skip to content

Commit 8ba240a

Browse files
committed
Fix bug #66921 - Wrong argument type hint for function intltz_from_date_time_zone
1 parent 8ddf9a2 commit 8ba240a

File tree

3 files changed

+20
-3
lines changed

3 files changed

+20
-3
lines changed

NEWS

+4-2
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ PHP NEWS
2121
. Fixed bug #67531 (syslog cannot be set in pool configuration). (Remi)
2222

2323
- Intl:
24+
. Fixed bug #66921 (Wrong argument type hint for function
25+
intltz_from_date_time_zone). (Stas)
2426
. Fixed bug #67052 (NumberFormatter::parse() resets LC_NUMERIC setting).
2527
(Stas)
2628

@@ -29,7 +31,7 @@ PHP NEWS
2931
happen) (Dmitry, Laruence)
3032

3133
- pgsql:
32-
. Fix bug #67550 (Error in code "form" instead of "from", pgsql.c, line 756),
34+
. Fixed bug #67550 (Error in code "form" instead of "from", pgsql.c, line 756),
3335
which affected builds against libpq < 7.3. (Adam)
3436

3537
- SPL:
@@ -40,7 +42,7 @@ PHP NEWS
4042
- Streams:
4143
. Fixed bug #67430 (http:// wrapper doesn't follow 308 redirects). (Adam)
4244

43-
?? ??? 2014, PHP 5.5.14
45+
27 Jun 2014, PHP 5.5.14
4446

4547
- Core:
4648
. Fixed BC break introduced by patch for bug #67072. (Anatol, Stas)

ext/intl/php_intl.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -445,7 +445,7 @@ ZEND_BEGIN_ARG_INFO_EX( arginfo_tz_idarg_static, 0, 0, 1 )
445445
ZEND_END_ARG_INFO()
446446

447447
ZEND_BEGIN_ARG_INFO_EX( arginfo_tz_from_date_time_zone, 0, 0, 1 )
448-
ZEND_ARG_OBJ_INFO( 0, dateTimeZone, IntlDateTimeZone, 0 )
448+
ZEND_ARG_OBJ_INFO( 0, dateTimeZone, DateTimeZone, 0 )
449449
ZEND_END_ARG_INFO()
450450

451451
ZEND_BEGIN_ARG_INFO_EX( arginfo_tz_create_enumeration, 0, 0, 0 )

ext/intl/tests/bug66921.phpt

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
--TEST--
2+
Bug #66921 - Wrong argument type hint for function intltz_from_date_time_zone
3+
--SKIPIF--
4+
<?php if( !extension_loaded( 'intl' ) ) print 'skip'; ?>
5+
--FILE--
6+
<?php
7+
$f = new ReflectionFunction('intltz_from_date_time_zone');
8+
var_dump($f->getParameters()[0]->getClass());
9+
10+
?>
11+
--EXPECTF--
12+
object(ReflectionClass)#%d (1) {
13+
["name"]=>
14+
string(12) "DateTimeZone"
15+
}

0 commit comments

Comments
 (0)