[Python-checkins] r87133 - python/branches/py3k/Doc/whatsnew/3.2.rst

alexander.belopolsky python-checkins at python.org
Wed Dec 8 22:21:56 CET 2010


Author: alexander.belopolsky
Date: Wed Dec  8 22:21:56 2010
New Revision: 87133

Log:
Added a datetime new features entry

Modified:
   python/branches/py3k/Doc/whatsnew/3.2.rst

Modified: python/branches/py3k/Doc/whatsnew/3.2.rst
==============================================================================
--- python/branches/py3k/Doc/whatsnew/3.2.rst	(original)
+++ python/branches/py3k/Doc/whatsnew/3.2.rst	Wed Dec  8 22:21:56 2010
@@ -609,6 +609,27 @@
   (Contributed by Raymond Hettinger and incorporating design suggestions
   from Mark Dickinson.)
 
+.. XXX: Add a section describing new feature added to datetime module
+
+   * The :mod:`datetime` received several new features including
+
+     - A new type, :class:`timezone` that implements :class:`tzinfo`
+       interface by returning fixed UTC offset and timezone name. This
+       makes it easier to create aware :class:datetime` objects::
+
+       >>> datetime.datetime.now(datetime.timezone.utc)
+       datetime.datetime(2010, 12, 8, 21, 4, 2, 923754, tzinfo=datetime.timezone.utc)
+
+       >>> datetime.datetime.strptime("01/01/2000 12:00 +0000", "%m/%d/%Y %H:%M %z")
+       datetime.datetime(2000, 1, 1, 12, 0, tzinfo=datetime.timezone.utc)
+
+      (See :issue:`5094` and :issue:`6641`.)
+
+     - :class: timedelta objects can now be multiplied by float and
+       divided by float and int objects.
+
+       (See :issue:`1289118`.)
+
 * The :mod:`nntplib` module gets a revamped implementation with better bytes and
   unicode semantics as well as more practical APIs.  These improvements break
   compatibility with the nntplib version in Python 3.1, which was partly


More information about the Python-checkins mailing list