[Python-3000] format and datetime (original) (raw)

"Martin v. Löwis" martin at v.loewis.de
Mon Sep 10 16:56:05 CEST 2007


I have a patch to add format to datetime.time, .date, and .datetime. For non-empty formatspec's, I just pass on to .strftime. For empty formatspec's, it returns str(self).

I think this is the only reasonable interpretation of formatspec's for datetime. Does anyone think otherwise?

Can you please show an example of how it would look like?

Regards, Martin



More information about the Python-3000 mailing list