svn: /php/php-src/ branches/PHP_5_3/NEWS branches/PHP_5_3/ext/intl/php_intl.c branches/PHP_5_3/ext/intl/tests/intl_icu_version_constant.phpt
branches/PHP_5_4/ext/intl/php_intl.c branches/PHP_5_4/ext/intl/tests/intl_icu_version_constant.phpt trunk/ext/intl/php_intl.c
trunk/ext/intl/tests/intl_icu_version_constant.phpt
| From: | Ilia Alshanetsky | Date: | Wed, 01 Jun 2011 16:26:21 +0000 |
| Subject: | svn: /php/php-src/ branches/PHP_5_3/NEWS branches/PHP_5_3/ext/intl/php_intl.c branches/PHP_5_3/ext/intl/tests/intl_icu_version_constant.phpt branches/PHP_5_4/ext/intl/php_intl.c branches/PHP_5_4/ext/intl/tests/intl_icu_version_constant.phpt trunk/ext/intl/php_intl.c trunk/ext/intl/tests/intl_icu_version_constant.phpt |
||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-65082@lists.php.net to get a copy of this message | ||
iliaa Wed, 01 Jun 2011 16:26:21 +0000
Revision: http://svn.php.net/viewvc?view=revision&revision=311714
Log:
Implemented FR #54561 (Expose ICU Version & ICU Data Version info).
Bug: http://bugs.php.net/54561 (Assigned) Expose ICU version
info
Changed paths:
U php/php-src/branches/PHP_5_3/NEWS
U php/php-src/branches/PHP_5_3/ext/intl/php_intl.c
A php/php-src/branches/PHP_5_3/ext/intl/tests/intl_icu_version_constant.phpt
U php/php-src/branches/PHP_5_4/ext/intl/php_intl.c
A php/php-src/branches/PHP_5_4/ext/intl/tests/intl_icu_version_constant.phpt
U php/php-src/trunk/ext/intl/php_intl.c
A php/php-src/trunk/ext/intl/tests/intl_icu_version_constant.phpt
Modified: php/php-src/branches/PHP_5_3/NEWS
===================================================================
--- php/php-src/branches/PHP_5_3/NEWS 2011-06-01 16:23:43 UTC (rev 311713)
+++ php/php-src/branches/PHP_5_3/NEWS 2011-06-01 16:26:21 UTC (rev 311714)
@@ -90,6 +90,7 @@
- intl extension:
. Implemented FR #54540 (Allow loading of arbitrary resource bundles when
fallback is disabled). (David Zuelke, Stas)
+ . Implemented FR #54561 (Expose ICU version info). (David Zuelke, Ilia)
- json extension:
. Fixed bug #54484 (Empty string in json_decode doesn't reset
Modified: php/php-src/branches/PHP_5_3/ext/intl/php_intl.c
===================================================================
--- php/php-src/branches/PHP_5_3/ext/intl/php_intl.c 2011-06-01 16:23:43 UTC (rev 311713)
+++ php/php-src/branches/PHP_5_3/ext/intl/php_intl.c 2011-06-01 16:26:21 UTC (rev 311714)
@@ -543,6 +543,10 @@
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 );
Added: php/php-src/branches/PHP_5_3/ext/intl/tests/intl_icu_version_constant.phpt
===================================================================
--- php/php-src/branches/PHP_5_3/ext/intl/tests/intl_icu_version_constant.phpt
(rev 0)
+++ php/php-src/branches/PHP_5_3/ext/intl/tests/intl_icu_version_constant.phpt 2011-06-01 16:26:21
UTC (rev 311714)
@@ -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)
Modified: php/php-src/branches/PHP_5_4/ext/intl/php_intl.c
===================================================================
--- php/php-src/branches/PHP_5_4/ext/intl/php_intl.c 2011-06-01 16:23:43 UTC (rev 311713)
+++ php/php-src/branches/PHP_5_4/ext/intl/php_intl.c 2011-06-01 16:26:21 UTC (rev 311714)
@@ -590,6 +590,10 @@
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 );
Added: php/php-src/branches/PHP_5_4/ext/intl/tests/intl_icu_version_constant.phpt
===================================================================
--- php/php-src/branches/PHP_5_4/ext/intl/tests/intl_icu_version_constant.phpt
(rev 0)
+++ php/php-src/branches/PHP_5_4/ext/intl/tests/intl_icu_version_constant.phpt 2011-06-01 16:26:21
UTC (rev 311714)
@@ -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)
Modified: php/php-src/trunk/ext/intl/php_intl.c
===================================================================
--- php/php-src/trunk/ext/intl/php_intl.c 2011-06-01 16:23:43 UTC (rev 311713)
+++ php/php-src/trunk/ext/intl/php_intl.c 2011-06-01 16:26:21 UTC (rev 311714)
@@ -590,6 +590,10 @@
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 );
Added: php/php-src/trunk/ext/intl/tests/intl_icu_version_constant.phpt
===================================================================
--- php/php-src/trunk/ext/intl/tests/intl_icu_version_constant.phpt (rev 0)
+++ php/php-src/trunk/ext/intl/tests/intl_icu_version_constant.phpt 2011-06-01 16:26:21 UTC (rev
311714)
@@ -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)