[Patches] [ python-Patches-570727 ] Code modernization for calendar.py

noreply@sourceforge.net noreply@sourceforge.net
Wed, 19 Jun 2002 20:48:10 -0700


Patches item #570727, was opened at 2002-06-18 14:17
You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=305470&aid=570727&group_id=5470

Category: Library (Lib)
Group: Python 2.3
>Status: Closed
>Resolution: Accepted
Priority: 5
Submitted By: Raymond Hettinger (rhettinger)
Assigned to: Raymond Hettinger (rhettinger)
Summary: Code modernization for calendar.py

Initial Comment:
Eliminated the indexer() logic from the i18n code in 
calendar.py.  The code is no longer necessary 
because Py2.3 lists support slice objects directly.

If approved, please re-assign to GvR.  Pending the 
introduction of a datetime module, he wants to avoid 
maintenance to calendar.  OTOH, he has been 
supportive of eliminating references to the types 
module and of modernizing code to take advantage of 
Py2.3 language features.

----------------------------------------------------------------------

>Comment By: Raymond Hettinger (rhettinger)
Date: 2002-06-19 22:48

Message:
Logged In: YES 
user_id=80475

Committed as calendar.py 1.28
Closing patch.

It was part of an effort to modernize and document a 
number of modules.  This particular fragment used the 
types module, had a weird isinstance check, and was 
harder to read than most python code.

In general, modules and peps attract attention in 
proportion to their understandabilty.  More people can 
grapple with calendar than with the nuances of internet 
protocols.

----------------------------------------------------------------------

Comment By: Guido van Rossum (gvanrossum)
Date: 2002-06-19 22:22

Message:
Logged In: YES 
user_id=6380

This is OK, but I wonder, why bother? Why does the calendar
module attract so much attention while many other modules
could use it better? :-)

----------------------------------------------------------------------

You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=305470&aid=570727&group_id=5470