summaryrefslogtreecommitdiff
path: root/annotations/generate_annotated_java_files.py
diff options
context:
space:
mode:
authorNeil Fuller <nfuller@google.com>2018-01-26 16:23:49 +0000
committerNeil Fuller <nfuller@google.com>2018-01-29 20:58:06 +0000
commitfb1a78d35d56cc48cc5ec5503d2bfff3406b923f (patch)
treea38d6a7d74fc290f1e8bf8b468c1a1ef96a0769b /annotations/generate_annotated_java_files.py
parent4bbec76841077a51b59978fcb7973bb6d96f3433 (diff)
Remove special UTC handling in SimpleDateFormat
ICU59 introduced support for localized UTC names. Special-case formating / parsing logic for UTC can therefore be removed from SimpleDateFormat. This change removes the explicit UTC logic and adds some new tests. In reality the SimpleDateFormat change means that: 1) Formatting "zzzz" will generate a long localized string (previously it would have produced "UTC"). 2) Parsing "zzzz" is unchanged as SimpleDateFormat was already doing a lookup in ICU if the timezone string wasn't an exact match for "UTC". 3) "z" formatting and parsing behavior is unchanged as the short form of UTC offered for most languages by ICU is "UTC". There may be compatibility issues for apps that have come to assume "UTC" is the output for "zzzz" all languages. The only one of the new tests that fails under the old scheme is: libcore.java.text.SimpleDateFormatTest#testFormatUtcLong because the test has explicit expecations around the "zzzz" form of UTC. Test: CTS: run cts -m CtsLibcoreTestCases Bug: 36337342 Change-Id: Ia8daa49420af82ed69b00bf8e75e0c8727f6bd1f
Diffstat (limited to 'annotations/generate_annotated_java_files.py')
0 files changed, 0 insertions, 0 deletions