When I use '^' flag, it was throwing exception.
you have moved flags to different file (java.util.FormattableFlags),
which has UPPERCASE (=2) as flag.
When i did a diff between build 48 and build 49 source i could find
the following method has a missed UPPERCASE support.
line 4056 : of Formatter.java file method :
private static Flags parse(char c) {
...
}
has switch statement and there is no
case for '^' : return UPPERCASE;
And i could see UPPERCASE usage in many places of that java file.
<console>
viswadeep:/home/vv145429/tiger/bugs/formatting 37 % java -version
java version "1.5.0-auto-tiger"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0-auto-tiger-112a)
Java HotSpot(TM) Client VM (build 1.5.0-beta2-b47, mixed mode)
viswadeep:/home/vv145429/tiger/bugs/formatting 38 % javac Test1_1.java
viswadeep:/home/vv145429/tiger/bugs/formatting 39 % java Test1_1.^R
java Test1_1
Exception in thread "main" java.util.UnknownFormatConversionException: Conversion = '^'
at java.util.Formatter.checkText(Formatter.java:2485)
at java.util.Formatter.parse(Formatter.java:2467)
at java.util.Formatter.format(Formatter.java:2396)
at java.io.PrintStream.format(PrintStream.java:899)
at Test1_1.main(Test1_1.java:5)
viswadeep:/home/vv145429/tiger/bugs/formatting 40 % cat Test1_1.java
import java.util.*;
public class Test1_1 {
public static void main(String[] arg) {
System.out.format("in uppercase = %^s","java");
}
}
viswadeep:/home/vv145429/tiger/bugs/formatting 41 %