mirror of
https://github.com/python/cpython.git
synced 2025-11-24 20:30:18 +00:00
Allow am/pm as well as AM/PM (C9X behaviour).
This commit is contained in:
parent
a454ebd924
commit
00ce51e38e
1 changed files with 2 additions and 2 deletions
|
|
@ -23,8 +23,8 @@ def strftest(now):
|
||||||
gmt = time.gmtime(now)
|
gmt = time.gmtime(now)
|
||||||
now = time.localtime(now)
|
now = time.localtime(now)
|
||||||
|
|
||||||
if now[3] < 12: ampm='AM'
|
if now[3] < 12: ampm='(AM|am)'
|
||||||
else: ampm='PM'
|
else: ampm='(PM|pm)'
|
||||||
|
|
||||||
jan1 = time.localtime(time.mktime((now[0], 1, 1) + (0,)*6))
|
jan1 = time.localtime(time.mktime((now[0], 1, 1) + (0,)*6))
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue