Subject: | Documentation for Z+ CLDR patterns is incorrect |
DateTime's CLDR Patterns documentation says:
Z{1,3} The time zone short name and the offset as one string, so
something like "CDT-0500".
ZZZZ The time zone long name.
However, what the format_cldr function actually *does* is:
Z{1,3} The time zone offset (like "-0500")
ZZZZ The time zone short name and the offset as one string, so
something like "CDT-0500".
Since the actual behavior is more useful than the documented behavior,
I'm calling this a documentation bug. (According to the documentation,
there's no way to get just the offset without the short name.) Also,
that means you can fix it without breaking anybody's code.