diff --git a/src/Symfony/Component/Intl/Intl.php b/src/Symfony/Component/Intl/Intl.php index cb14e334d0..21031b5bbb 100644 --- a/src/Symfony/Component/Intl/Intl.php +++ b/src/Symfony/Component/Intl/Intl.php @@ -234,7 +234,7 @@ final class Intl */ public static function getIcuStubVersion() { - return '51.2'; + return '55.1'; } /** diff --git a/src/Symfony/Component/Intl/NumberFormatter/NumberFormatter.php b/src/Symfony/Component/Intl/NumberFormatter/NumberFormatter.php index 7bc7a2ba88..f89ce8a469 100644 --- a/src/Symfony/Component/Intl/NumberFormatter/NumberFormatter.php +++ b/src/Symfony/Component/Intl/NumberFormatter/NumberFormatter.php @@ -239,7 +239,7 @@ class NumberFormatter private static $enTextAttributes = array( self::DECIMAL => array('', '', '-', '', '*', '', ''), - self::CURRENCY => array('¤', '', '(¤', ')', '*', ''), + self::CURRENCY => array('¤', '', '-¤', '', '*', ''), ); /** @@ -337,7 +337,7 @@ class NumberFormatter $ret = $symbol.$value; - return $negative ? '('.$ret.')' : $ret; + return $negative ? '-'.$ret : $ret; } /** diff --git a/src/Symfony/Component/Intl/Tests/NumberFormatter/AbstractNumberFormatterTest.php b/src/Symfony/Component/Intl/Tests/NumberFormatter/AbstractNumberFormatterTest.php index 53fd4f7238..80e22aa69b 100644 --- a/src/Symfony/Component/Intl/Tests/NumberFormatter/AbstractNumberFormatterTest.php +++ b/src/Symfony/Component/Intl/Tests/NumberFormatter/AbstractNumberFormatterTest.php @@ -64,15 +64,15 @@ abstract class AbstractNumberFormatterTest extends \PHPUnit_Framework_TestCase { return array( array(100, 'ALL', 'ALL100'), - array(-100, 'ALL', '(ALL100)'), + array(-100, 'ALL', '-ALL100'), array(1000.12, 'ALL', 'ALL1,000'), array(100, 'JPY', '¥100'), - array(-100, 'JPY', '(¥100)'), + array(-100, 'JPY', '-¥100'), array(1000.12, 'JPY', '¥1,000'), array(100, 'EUR', '€100.00'), - array(-100, 'EUR', '(€100.00)'), + array(-100, 'EUR', '-€100.00'), array(1000.12, 'EUR', '€1,000.12'), ); } @@ -90,7 +90,7 @@ abstract class AbstractNumberFormatterTest extends \PHPUnit_Framework_TestCase { return array( array(100, 'CRC', 'CRC', '%s100'), - array(-100, 'CRC', 'CRC', '(%s100)'), + array(-100, 'CRC', 'CRC', '-%s100'), array(1000.12, 'CRC', 'CRC', '%s1,000'), ); } @@ -108,7 +108,7 @@ abstract class AbstractNumberFormatterTest extends \PHPUnit_Framework_TestCase { return array( array(100, 'BRL', 'R', '%s$100.00'), - array(-100, 'BRL', 'R', '(%s$100.00)'), + array(-100, 'BRL', 'R', '-%s$100.00'), array(1000.12, 'BRL', 'R', '%s$1,000.12'), // Rounding checks @@ -135,7 +135,7 @@ abstract class AbstractNumberFormatterTest extends \PHPUnit_Framework_TestCase { return array( array(100, 'CHF', 'CHF', '%s100.00'), - array(-100, 'CHF', 'CHF', '(%s100.00)'), + array(-100, 'CHF', 'CHF', '-%s100.00'), array(1000.12, 'CHF', 'CHF', '%s1,000.12'), array('1000.12', 'CHF', 'CHF', '%s1,000.12'), @@ -216,7 +216,7 @@ abstract class AbstractNumberFormatterTest extends \PHPUnit_Framework_TestCase return array( array($formatter, 1, '¤1.00'), array($formatter, 1.1, '¤1.00'), - array($formatter, 2147483648, '(¤2,147,483,648.00)', $message), + array($formatter, 2147483648, '-¤2,147,483,648.00', $message), array($formatter, -2147483649, '¤2,147,483,647.00', $message), ); } @@ -261,7 +261,7 @@ abstract class AbstractNumberFormatterTest extends \PHPUnit_Framework_TestCase array($formatter, 1, '¤1.00'), array($formatter, 1.1, '¤1.00'), array($formatter, 2147483648, '¤2,147,483,648.00'), - array($formatter, -2147483649, '(¤2,147,483,649.00)'), + array($formatter, -2147483649, '-¤2,147,483,649.00'), ); }