summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1992-07-09 11:05:12 (GMT)
committerGuido van Rossum <guido@python.org>1992-07-09 11:05:12 (GMT)
commiteb23155a8e8e07b8f1d6e6085e7a3a45cc605d55 (patch)
tree153c59dad60adeee16fdbe67a053f3e107902c76 /Lib
parentca7b213b469fe07f0fadb78901f1b25957bab4ef (diff)
downloadcpython-eb23155a8e8e07b8f1d6e6085e7a3a45cc605d55.zip
cpython-eb23155a8e8e07b8f1d6e6085e7a3a45cc605d55.tar.gz
cpython-eb23155a8e8e07b8f1d6e6085e7a3a45cc605d55.tar.bz2
Changed calendar.py to define lists of literals instead of tuples.
Got rid of old module 'localtime.py'.
Diffstat (limited to 'Lib')
-rw-r--r--Lib/calendar.py18
1 files changed, 9 insertions, 9 deletions
diff --git a/Lib/calendar.py b/Lib/calendar.py
index f00268b..4e02e0e 100644
--- a/Lib/calendar.py
+++ b/Lib/calendar.py
@@ -23,7 +23,7 @@ January = 1
February = 2
# Number of days per month (except for February in leap years)
-mdays = (0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31)
+mdays = [0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31]
# Exception raised for bad input (with string parameter for details)
error = 'calendar error'
@@ -67,16 +67,16 @@ def mktime(year, month, day, hours, mins, secs):
return ((days*24 + hours)*60 + mins)*60 + secs
# Full and abbreviated names of weekdays
-day_name = ('Monday', 'Tuesday', 'Wednesday', 'Thursday')
-day_name = day_name + ('Friday', 'Saturday', 'Sunday')
-day_abbr = ('Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun')
+day_name = ['Monday', 'Tuesday', 'Wednesday', 'Thursday', \
+ 'Friday', 'Saturday', 'Sunday']
+day_abbr = ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun']
# Full and abbreviated of months (1-based arrays!!!)
-month_name = ('', 'January', 'February', 'March', 'April')
-month_name = month_name + ('May', 'June', 'July', 'August')
-month_name = month_name + ('September', 'October', 'November', 'December')
-month_abbr = (' ', 'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun')
-month_abbr = month_abbr + ('Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec')
+month_name = ['', 'January', 'February', 'March', 'April', \
+ 'May', 'June', 'July', 'August', \
+ 'September', 'October', 'November', 'December']
+month_abbr = [' ', 'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', \
+ 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec']
# Zero-fill string to two positions (helper for asctime())
def dd(s):