summaryrefslogtreecommitdiffstats
path: root/Misc/NEWS
diff options
context:
space:
mode:
authorMark Dickinson <dickinsm@gmail.com>2009-07-05 10:01:24 (GMT)
committerMark Dickinson <dickinsm@gmail.com>2009-07-05 10:01:24 (GMT)
commit463dc4bf26c37c5f90cfe9328087976a0bdc5757 (patch)
tree5d8a0bcbd0a219f46f60b8125d9203c4dc4e22fa /Misc/NEWS
parent5b1abb7bb0553c0f9ed41bf75d1003eb47a86013 (diff)
downloadcpython-463dc4bf26c37c5f90cfe9328087976a0bdc5757.zip
cpython-463dc4bf26c37c5f90cfe9328087976a0bdc5757.tar.gz
cpython-463dc4bf26c37c5f90cfe9328087976a0bdc5757.tar.bz2
Issues #1530559, #1741130: Fix various inconsistencies in struct.pack
integer packing, and reenable some previously broken tests.
Diffstat (limited to 'Misc/NEWS')
-rw-r--r--Misc/NEWS15
1 files changed, 15 insertions, 0 deletions
diff --git a/Misc/NEWS b/Misc/NEWS
index 971b25e..e18fe3c 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -1167,6 +1167,21 @@ C-API
Extension Modules
-----------------
+- Issues #1530559, #1741130: Fix various struct.pack inconsistencies
+ for the integer formats ('bBhHiIlLqQ'). In the following, '*'
+ represents any of '=', '<', '>'.
+
+ - Packing a float now always gives a Deprecation Warning.
+ Previously it only warned for 'I', 'L', '*B', '*H', '*I', '*L'.
+
+ - If x is not an int, long or float, then packing x will always
+ result in struct.error. Previously an x with an __int__ method
+ could be packed by 'b', 'B', 'h', 'H', 'i', 'l', '*b', '*h'
+ ,'*i', '*l', and an x with a __long__ method could be packed by
+ 'q', 'Q', '*q', '*Q'; for x with neither __int__ nor __long__,
+ TypeError used to be raised (with a confusing error message) for
+ 'I', 'L', '*B', '*H', '*I', '*L', and struct.error in other cases.
+
- Issue #4873: Fix resource leaks in error cases of pwd and grp.
- Issue #4751: For hashlib algorithms provided by OpenSSL, the Python