Skip to content

Commit ae0a0f5

Browse files
committed
64 bit split
1 parent c370ad8 commit ae0a0f5

File tree

2 files changed

+19
-7
lines changed

2 files changed

+19
-7
lines changed
Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
--TEST--
2-
IntlTimeZone::createTimeZoneIDEnumeration(): errors
2+
IntlTimeZone::createTimeZoneIDEnumeration() invalid zone type
33
--EXTENSIONS--
44
intl
55
--FILE--
@@ -10,12 +10,7 @@ try {
1010
} catch (Throwable $e) {
1111
echo $e::class, ': ', $e->getMessage(), PHP_EOL;
1212
}
13-
try {
14-
var_dump(IntlTimeZone::createTimeZoneIDEnumeration(IntlTimeZone::TYPE_ANY, '', PHP_INT_MAX));
15-
} catch (Throwable $e) {
16-
echo $e::class, ': ', $e->getMessage(), PHP_EOL;
17-
}
13+
1814
?>
1915
--EXPECT--
2016
ValueError: IntlTimeZone::createTimeZoneIDEnumeration(): Argument #1 ($type) must be one of IntlTimeZone::TYPE_ANY, IntlTimeZone::TYPE_CANONICAL, or IntlTimeZone::TYPE_CANONICAL_LOCATION
21-
ValueError: IntlTimeZone::createTimeZoneIDEnumeration(): Argument #1 ($type) must be between -2147483648 and 2147483647
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
--TEST--
2+
IntlTimeZone::createTimeZoneIDEnumeration() offset out of range
3+
--EXTENSIONS--
4+
intl
5+
--SKIPIF--
6+
<?php if (PHP_INT_SIZE != 8) die("skip this test is for 64bit platform only"); ?>
7+
--FILE--
8+
<?php
9+
10+
try {
11+
var_dump(IntlTimeZone::createTimeZoneIDEnumeration(IntlTimeZone::TYPE_ANY, '', PHP_INT_MAX));
12+
} catch (Throwable $e) {
13+
echo $e::class, ': ', $e->getMessage(), PHP_EOL;
14+
}
15+
?>
16+
--EXPECT--
17+
ValueError: IntlTimeZone::createTimeZoneIDEnumeration(): Argument #1 ($type) must be between -2147483648 and 2147483647

0 commit comments

Comments
 (0)