Re: [Python-Dev] Patch review: [ 1100942 ] datetime.strptime constructor added

2005-01-26 Thread Skip Montanaro
Alan> 1. In the time module, the strptime() function's format Alan> parameter is optional. For consistency's sake, I'd expect Alan> datetime.strptime()'s format parameter also to be optional. (On Alan> the other hand, the default value for the format is not very Alan> useful.

[Python-Dev] Patch review: [ 1100942 ] datetime.strptime constructor added

2005-01-26 Thread Alan Green
I see a need for this patch - I've had to write "datetime(*(time.strptime(date_string, format)[0:6]))" far too many times. I don't understand the C API well enough to check if reference counts are handled properly, but otherwise the implementation looks straight forward. Documentation looks good