[Python-Dev] strftime() (original) (raw)

Tim Peters tim_one@email.msn.com
Sun, 6 Aug 2000 01:07:27 -0400


[Jack Jansen]

The teststrftime regression test has been failing on the Mac for ages, and I finally got round to investigating the problem: the MetroWerks library returns the strings "am" and "pm" for %p but the regression test expects "AM" and "PM". According to the comments in the source of the library (long live vendors who provide it! Yeah!) this is C9X compatibility.

My copy of a draft C99 std agrees (7.23.3.5) with MetroWerks on this point (i.e., that %p in the "C" locale becomes "am" or "pm").

I can of course move the %p to the nonstandard expectations, but maybe someone has a better idea?

Not really. If Python thinks this function is valuable, it "should" offer a platform-independent implementation, but as nobody has time for that ...