[Python-3000] cleaning up *path.py code duplication (original) (raw)
Jack Diederich jackdied at jackdied.com
Sat Aug 26 02:19:23 CEST 2006
- Previous message: [Python-3000] PyString C API
- Next message: [Python-3000] cleaning up *path.py code duplication
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
While checking find() uses in the stdlib I noticed that the various path modules have duplicate code and docstrings for some generic path manipulations. Delightfully they even have different implementations and docstrings for identical functions. splitext() is a great bad example - os2emxpath.splitext() builds up strings by doing char-by-char concatenations where everyone else uses find() + slice.
If there are no objections I'll move these into a module named genericpath.py and change the others to do
from genericpath import func1, func2, funcN
where applicable.
So, any objections? Should it be a 2.6 backport too?
-Jack
- Previous message: [Python-3000] PyString C API
- Next message: [Python-3000] cleaning up *path.py code duplication
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]