-
Bug
-
Resolution: Fixed
-
P4
-
None
-
b02
-
generic
-
generic
-
Verified
A DESCRIPTION OF THE PROBLEM:
Incorrect currency instance is returned by the Currency.getInstance() method
STEPS TO REPRODUCE THE PROBLEM:
1. supersede currency.properties
currency.properties
MA=MAA,555,5
MC=MAA,555,6
2. Used the below code snippet:
Currency cur1 = Currency.getInstance(new Locale("", "MA"));
System.out.println(cur1.getCurrencyCode()+": "+cur1.getDefaultFractionDigits());
Currency cur2 = Currency.getInstance(new Locale("", "MC"));
System.out.println(cur2.getCurrencyCode()+": "+cur2.getDefaultFractionDigits());
Actual Output
MAA: 5
MAA: 5
Expected Output
MAA: 5
MAA: 6
Incorrect currency instance is returned by the Currency.getInstance() method
STEPS TO REPRODUCE THE PROBLEM:
1. supersede currency.properties
currency.properties
MA=MAA,555,5
MC=MAA,555,6
2. Used the below code snippet:
Currency cur1 = Currency.getInstance(new Locale("", "MA"));
System.out.println(cur1.getCurrencyCode()+": "+cur1.getDefaultFractionDigits());
Currency cur2 = Currency.getInstance(new Locale("", "MC"));
System.out.println(cur2.getCurrencyCode()+": "+cur2.getDefaultFractionDigits());
Actual Output
MAA: 5
MAA: 5
Expected Output
MAA: 5
MAA: 6
- csr for
-
JDK-8196835 Incorrect currency instance returned by java.util.Currency.getInstance()
- Closed
- relates to
-
JDK-8190196 java.util.Currency has no equals() method
- Closed