[libc++][chrono] Improves date formatting. (#86127)

The formatting of years has been done manually since the results of %Y
outside the "typical" range may produce unexpected values. The same
applies to %F which is identical to %Y-%m-%d. None of these conversion
specifiers is affected by the locale used. So it's trivial to manually
handle this case.

This removes several platform specific ifdefs from the tests.

GitOrigin-RevId: 812963f6aa2adb5e990f273b8ce1a0eabcdefd7f
4 files changed