[Python-Dev] cpython (3.2): #14766: Add correct algorithm for when a 'time' object is naive. (original) (raw)
Georg Brandl g.brandl at gmx.net
Mon May 21 19:46:59 CEST 2012
- Previous message: [Python-Dev] cpython: Close #13585: add contextlib.ExitStack to replace the ill-fated
- Next message: [Python-Dev] cpython: Close #14588: added a PEP 3115 compliant dynamic type creation mechanism
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Am 15.05.2012 04:33, schrieb r.david.murray:
diff --git a/Doc/library/datetime.rst b/Doc/library/datetime.rst --- a/Doc/library/datetime.rst +++ b/Doc/library/datetime.rst @@ -15,16 +15,23 @@ formatting and manipulation. For related functionality, see also the :mod:
time
and :mod:calendar
modules.-There are two kinds of date and time objects: "naive" and "aware". This -distinction refers to whether the object has any notion of time zone, daylight -saving time, or other kind of algorithmic or political time adjustment. Whether -a naive :class:
.datetime
object represents Coordinated Universal Time (UTC), +There are two kinds of date and time objects: "naive" and "aware". + +An aware object has sufficient knowledge of applicable algorithmic and +political time adjustments, such as time zone and daylight saving time +information, to locate itself relative to other aware objects. An aware object +is used to represent a specific moment in time that is not open to +interpretation [#].
@@ -1806,3 +1816,7 @@ When the
%z
directive is provided to the :meth:strptime
method, an aware :class:.datetime
object will be produced. Thetzinfo
of the result will be set to a :class:timezone
instance. + +.. rubric:: Footnotes + +.. [#] If, that is, we ignore the effects of Relativity
I like that :)
Georg
- Previous message: [Python-Dev] cpython: Close #13585: add contextlib.ExitStack to replace the ill-fated
- Next message: [Python-Dev] cpython: Close #14588: added a PEP 3115 compliant dynamic type creation mechanism
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]