Rafe Kaplan <ra...@google.com> added the comment: Alexander, about 1, that's a pretty good question. I had originally wanted to do something like that but Brett Cannon at the time thought it was not the right approach. I don't recall the details. Maybe Brett can recall. I think we had that conversation in person and it was a long time ago :(
I had originally thought of doing the class, and then having constants associated with it: UTC.UTC0 Eventually if we support multiple timezones: UTC.UTC1 UTC.UTC2 UTC.UTC_1 UTC.UTC_2 Well... maybe not given how impossible the naming would be. I think we also talked about redefining new so that it would always return the same global instance. On 2, we had discussions about how to pass parameters in to utcnow that we DID record. When I suggested it, Brett said: "...using a boolean flag over an argument is much less error-prone for a developer from passing in the wrong timezone object; passing in something other than an instance of UTC would just be stupid so we should make sure the developer isn't stupid. =)" ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue5094> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com