mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Compatibility with old versions of ICU (4.0+).
This commit is contained in:
parent
69f75bb43c
commit
95fbae891a
33 changed files with 108 additions and 0 deletions
|
@ -189,6 +189,7 @@ U_CFUNC PHP_FUNCTION(intltz_count_equivalent_ids)
|
|||
RETURN_LONG((long)result);
|
||||
}
|
||||
|
||||
#if U_ICU_VERSION_MAJOR_NUM * 10 + U_ICU_VERSION_MINOR_NUM >= 48
|
||||
U_CFUNC PHP_FUNCTION(intltz_create_time_zone_id_enumeration)
|
||||
{
|
||||
long zoneType,
|
||||
|
@ -243,6 +244,7 @@ U_CFUNC PHP_FUNCTION(intltz_create_time_zone_id_enumeration)
|
|||
|
||||
IntlIterator_from_StringEnumeration(se, return_value TSRMLS_CC);
|
||||
}
|
||||
#endif
|
||||
|
||||
U_CFUNC PHP_FUNCTION(intltz_get_canonical_id)
|
||||
{
|
||||
|
@ -283,6 +285,7 @@ U_CFUNC PHP_FUNCTION(intltz_get_canonical_id)
|
|||
}
|
||||
}
|
||||
|
||||
#if U_ICU_VERSION_MAJOR_NUM * 10 + U_ICU_VERSION_MINOR_NUM >= 48
|
||||
U_CFUNC PHP_FUNCTION(intltz_get_region)
|
||||
{
|
||||
char *str_id;
|
||||
|
@ -310,6 +313,7 @@ U_CFUNC PHP_FUNCTION(intltz_get_region)
|
|||
|
||||
RETURN_STRINGL(outbuf, region_len, 1);
|
||||
}
|
||||
#endif
|
||||
|
||||
U_CFUNC PHP_FUNCTION(intltz_get_tz_data_version)
|
||||
{
|
||||
|
@ -477,9 +481,11 @@ U_CFUNC PHP_FUNCTION(intltz_has_same_rules)
|
|||
|
||||
static const TimeZone::EDisplayType display_types[] = {
|
||||
TimeZone::SHORT, TimeZone::LONG,
|
||||
#if U_ICU_VERSION_MAJOR_NUM * 10 + U_ICU_VERSION_MINOR_NUM >= 44
|
||||
TimeZone::SHORT_GENERIC, TimeZone::LONG_GENERIC,
|
||||
TimeZone::SHORT_GMT, TimeZone::LONG_GMT,
|
||||
TimeZone::SHORT_COMMONLY_USED, TimeZone::GENERIC_LOCATION
|
||||
#endif
|
||||
};
|
||||
|
||||
U_CFUNC PHP_FUNCTION(intltz_get_display_name)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue