[Python-checkins] cpython: whatsnew: __complex__ may not return float, .so may have multiple python modules
r.david.murray
python-checkins at python.org
Tue Feb 11 14:13:52 CET 2014
http://hg.python.org/cpython/rev/7cfbebadb90b
changeset: 89149:7cfbebadb90b
parent: 89147:15a6be05e970
user: R David Murray <rdmurray at bitdance.com>
date: Tue Feb 11 08:13:10 2014 -0500
summary:
whatsnew: __complex__ may not return float, .so may have multiple python modules
Also a NEWS wording fixup.
files:
Doc/whatsnew/3.4.rst | 9 +++++++++
Misc/NEWS | 6 +++---
2 files changed, 12 insertions(+), 3 deletions(-)
diff --git a/Doc/whatsnew/3.4.rst b/Doc/whatsnew/3.4.rst
--- a/Doc/whatsnew/3.4.rst
+++ b/Doc/whatsnew/3.4.rst
@@ -1443,6 +1443,10 @@
values for its constants from the C header files, instead of having the
values hard-coded in the python module as was previously the case.
+* Loading multiple python modules from a single OS module (``.so``, ``.dll``)
+ now works correctly (previously it silently returned the first python
+ module in the file). (Contributed by Václav Šmilauer in :issue:`16421`.)
+
Significant Optimizations
@@ -1725,6 +1729,11 @@
:exc:`ValueError` if given a negative length; previously it returned nonsense
values (:issue:`14794`).
+* The :class:`complex` constructor, unlike the :mod:`cmath` functions, was
+ incorrectly accepting :class:`float` values if an object's ``__complex__``
+ special method returned one. This now raises a :exc:`TypeError`.
+ (:issue:`16290`.)
+
Changes in the C API
--------------------
diff --git a/Misc/NEWS b/Misc/NEWS
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -2262,10 +2262,10 @@
builtins.
- Issue #16455: On FreeBSD and Solaris, if the locale is C, the
- ASCII/surrogateescape codec is now used, instead of the locale encoding, to
+ ASCII/surrogateescape codec is now used (instead of the locale encoding) to
decode the command line arguments. This change fixes inconsistencies with
- os.fsencode() and os.fsdecode() because these operating systems announces an
- ASCII locale encoding, whereas the ISO-8859-1 encoding is used in practice.
+ os.fsencode() and os.fsdecode(), because these operating systems announce an
+ ASCII locale encoding, but actually use the ISO-8859-1 encoding in practice.
- Issue #16562: Optimize dict equality testing. Patch by Serhiy Storchaka.
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list