-
Bug
-
Resolution: Not an Issue
-
P3
-
None
-
11.0.2
-
x86_64
-
windows_10
ADDITIONAL SYSTEM INFORMATION :
Works in Java 8 202, broken in Java 11.0.1 and above (including Java 12 build 30)
A DESCRIPTION OF THE PROBLEM :
getDateInstance returns wrong pattern. I have only testes da and sv languages.
REGRESSION : Last worked in version 8u202
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Run the program and see the output
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
1.8.0_201
dd-MM-yy
yyyy-MM-dd
1.8.0_202
dd-MM-yy
yyyy-MM-dd
ACTUAL -
11.0.1
dd/MM/y
y-MM-dd
11.0.2
dd/MM/y
y-MM-dd
12-ea
dd/MM/y
y-MM-dd
---------- BEGIN SOURCE ----------
public class DateFormatTest1 {
public static void main(String[] args) {
System.out.println(System.getProperty("java.version"));
System.out.println(((SimpleDateFormat)DateFormat.getDateInstance(DateFormat.SHORT, new Locale("da", "DK"))).toPattern());
System.out.println(((SimpleDateFormat)DateFormat.getDateInstance(DateFormat.SHORT, new Locale("sv", "SE"))).toPattern());
}
}
---------- END SOURCE ----------
FREQUENCY : always
Works in Java 8 202, broken in Java 11.0.1 and above (including Java 12 build 30)
A DESCRIPTION OF THE PROBLEM :
getDateInstance returns wrong pattern. I have only testes da and sv languages.
REGRESSION : Last worked in version 8u202
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Run the program and see the output
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
1.8.0_201
dd-MM-yy
yyyy-MM-dd
1.8.0_202
dd-MM-yy
yyyy-MM-dd
ACTUAL -
11.0.1
dd/MM/y
y-MM-dd
11.0.2
dd/MM/y
y-MM-dd
12-ea
dd/MM/y
y-MM-dd
---------- BEGIN SOURCE ----------
public class DateFormatTest1 {
public static void main(String[] args) {
System.out.println(System.getProperty("java.version"));
System.out.println(((SimpleDateFormat)DateFormat.getDateInstance(DateFormat.SHORT, new Locale("da", "DK"))).toPattern());
System.out.println(((SimpleDateFormat)DateFormat.getDateInstance(DateFormat.SHORT, new Locale("sv", "SE"))).toPattern());
}
}
---------- END SOURCE ----------
FREQUENCY : always