Implemented FR #54561 (Expose ICU Version & ICU Data Version info).

This commit is contained in:
Ilia Alshanetsky committed 2011-06-01 16:26:21 +00:00
1 parent 8083c1ab89
commit ccd3633b5c
2 files changed
+14

No files matched your search

+4
View File
@@ -590,6 +590,10 @@ PHP_MINIT_FUNCTION( intl )
REGISTER_INI_ENTRIES();
REGISTER_LONG_CONSTANT("INTL_MAX_LOCALE_LEN", INTL_MAX_LOCALE_LEN, CONST_CS);
REGISTER_STRING_CONSTANT("INTL_ICU_VERSION", U_ICU_VERSION, CONST_PERSISTENT | CONST_CS);
#ifdef U_ICU_DATA_VERSION
REGISTER_STRING_CONSTANT("INTL_ICU_DATA_VERSION", U_ICU_DATA_VERSION, CONST_PERSISTENT | CONST_CS);
#endif
/* Register 'Collator' PHP class */
collator_register_Collator_class( TSRMLS_C );
@@ -0,0 +1,10 @@
--TEST--
INTL_ICU_VERSION constant
--SKIPIF--
<?php if( !extension_loaded( 'intl' ) ) print 'skip'; ?>
--FILE--
<?php
var_dump(defined("INTL_ICU_VERSION"));
?>
--EXPECT--
bool(true)