Message254255
I have committed changes to Python 3. The compile() test now exists as test_compile.TestSpecifics.test_null_terminated.
Serhiy: You set these bugs for Python 2 as well. Is there a way to produce a non-null-terminated buffer in Python 2 to help verify this? Both John’s original array() tests and the memoryview() tests don’t seem to be supported by Python 2’s idea of buffer objects:
>>> float(array.array("B",b"A"*0x10))
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: float() argument must be a string or a number
>>> float(memoryview(b"1234")[1:-1])
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: float() argument must be a string or a number
I have a half-ported patch for Python 2, but it would be nice to know (a) if it is actually needed, and (b) what to do about unit tests. |
|
Date |
User |
Action |
Args |
2015-11-07 05:35:35 | martin.panter | set | recipients:
+ martin.panter, mark.dickinson, eric.smith, python-dev, serhiy.storchaka, JohnLeitch |
2015-11-07 05:35:35 | martin.panter | set | messageid: <1446874535.66.0.011996607623.issue24802@psf.upfronthosting.co.za> |
2015-11-07 05:35:35 | martin.panter | link | issue24802 messages |
2015-11-07 05:35:34 | martin.panter | create | |
|