Commit Graph

5015 Commits

Author SHA1 Message Date
Serhiy Storchaka 0b2cacb42a Issue #20335: bytes constructor now raises TypeError when encoding or errors
is specified with non-string argument.  Based on patch by Renaud Blanch.
2014-12-02 09:26:14 +02:00
Serhiy Storchaka 83cf99d733 Issue #20335: bytes constructor now raises TypeError when encoding or errors
is specified with non-string argument.  Based on patch by Renaud Blanch.
2014-12-02 09:24:06 +02:00
Serhiy Storchaka 407249c62b Issue #22975: Close block at right place. 2014-12-01 18:56:54 +02:00
Serhiy Storchaka 133b11b566 Issue #22975: Close block at right place. 2014-12-01 18:56:28 +02:00
Benjamin Peterson 0a59d5563e merge 3.4 (#22954) 2014-11-26 23:03:34 -06:00
Benjamin Peterson e823933f9f remove tautological condition (closes #22954) 2014-11-26 23:03:11 -06:00
Nick Coghlan d600951748 Issue #22869: Split pythonrun into two modules
- interpreter startup and shutdown code moved to a new
  pylifecycle.c module
- Py_OptimizeFlag moved into the new module with the other
  global flags
2014-11-20 21:39:37 +10:00
Victor Stinner 3aa979e0cd Issue #20948: Inline makefmt() in unicode_fromformat_arg() 2014-11-18 21:40:51 +01:00
Antoine Pitrou 2a40e36739 Issue #22847: Improve method cache efficiency. 2014-11-15 00:56:27 +01:00
Antoine Pitrou 8a03896cac Issue #22335: Fix crash when trying to enlarge a bytearray to 0x7fffffff bytes on a 32-bit platform. 2014-11-02 18:41:56 +01:00
Antoine Pitrou cc23154d02 Issue #22335: Fix crash when trying to enlarge a bytearray to 0x7fffffff bytes on a 32-bit platform. 2014-11-02 18:40:09 +01:00
Georg Brandl b8fa289152 merge with 3.4 2014-10-31 13:13:09 +01:00
Georg Brandl e1d26f377e Closes #22772: fix __ifloordiv__ and __itruediv__ docstring. 2014-10-31 13:12:57 +01:00
Antoine Pitrou bc92bbd4d2 Issue #22653: Fix an assertion failure in debug mode when doing a reentrant dict insertion in debug mode. 2014-10-18 00:35:44 +02:00
Antoine Pitrou d696732025 Issue #22653: Fix an assertion failure in debug mode when doing a reentrant dict insertion in debug mode. 2014-10-18 00:35:00 +02:00
Benjamin Peterson fa5021699a Merge 3.3 2014-10-15 23:58:32 -04:00
Antoine Pitrou b6dc9b7554 Fixed signed/unsigned comparison warning 2014-10-15 23:14:53 +02:00
Antoine Pitrou 4e334241b7 Fixed signed/unsigned comparison warning 2014-10-15 23:14:53 +02:00
Benjamin Peterson 736982d36d merge 3.4 (closes #22643) 2014-10-15 12:17:47 -04:00
Benjamin Peterson 9c422f3c3d merge 3.3 2014-10-15 12:17:33 -04:00
Benjamin Peterson 1e211ff10d it suffices to check for PY_SSIZE_T_MAX overflow (#22643) 2014-10-15 12:17:21 -04:00
Benjamin Peterson 315aa40403 Merge 3.4 2014-10-15 11:51:17 -04:00
Benjamin Peterson 60d7a73194 Merge 3.3 2014-10-15 11:51:12 -04:00
Benjamin Peterson c0e64f5027 make sure length is unsigned 2014-10-15 11:51:05 -04:00
Benjamin Peterson 6925264334 merge 3.4 (#22643) 2014-10-15 11:49:15 -04:00
Benjamin Peterson 1cbb3fe775 merge 3.3 (#22643) 2014-10-15 11:48:41 -04:00
Benjamin Peterson e1bd38c03c fix integer overflow in unicode case operations (closes #22643) 2014-10-15 11:47:36 -04:00
Larry Hastings dfbeb160de Issue #22615: Argument Clinic now supports the "type" argument for the
int converter.  This permits using the int converter with enums and
typedefs.
2014-10-13 10:39:41 +01:00
Antoine Pitrou 759920c5cb Issue #22604: Fix assertion error in debug mode when dividing a complex number by (nan+0j). 2014-10-10 23:51:04 +02:00
Antoine Pitrou 9086f9260f Issue #22604: Fix assertion error in debug mode when dividing a complex number by (nan+0j). 2014-10-10 23:49:32 +02:00
R David Murray 861470c836 #16518: Bring error messages in harmony with docs ("bytes-like object")
Some time ago we changed the docs to consistently use the term 'bytes-like
object' in all the contexts where bytes, bytearray, memoryview, etc are used.
This patch (by Ezio Melotti) completes that work by changing the error
messages that previously reported that certain types did "not support the
buffer interface" to instead say that a bytes-like object is required.  (The
glossary entry for bytes-like object references the discussion of the buffer
protocol in the docs.)
2014-10-05 11:47:01 -04:00
Georg Brandl 72b8a80e59 Closes #22540: speed up PyObject_IsInstance and PyObject_IsSubclass in the common case that the second argument has metaclass "type". 2014-10-03 09:26:37 +02:00
Gregory P. Smith 8486f9b134 Fix "warning: comparison between signed and unsigned integer expressions"
-Wsign-compare warnings in unicodeobject.c.  These were all a result
of sizeof() being unsigned and being compared to a Py_ssize_t.
Not actual problems.
2014-09-30 00:33:24 -07:00
Benjamin Peterson fd97a6fb2d merge 3.4 (#22520) 2014-09-29 23:02:56 -04:00
Benjamin Peterson 43030ee780 merge 3.3 (#22520) 2014-09-29 23:02:35 -04:00
Benjamin Peterson 736b8012b4 prevent overflow in unicode_repr (closes #22520) 2014-09-29 23:02:15 -04:00
Benjamin Peterson cdfb7691dd merge 3.4 2014-09-29 19:12:44 -04:00
Benjamin Peterson c2cfa8ddd8 merge 3.3 2014-09-29 19:12:37 -04:00
Benjamin Peterson d48bc9468f these variables ought to be Py_ssize_t 2014-09-29 19:12:26 -04:00
Benjamin Peterson 36a24f3f43 merge 3.4 (#22519) 2014-09-29 19:11:05 -04:00
Benjamin Peterson 18f836fb65 merge 3.3 (closes #22519) 2014-09-29 19:09:49 -04:00
Benjamin Peterson 42ff105539 fix overflow checking in PyBytes_Repr (closes #22519) 2014-09-29 19:01:18 -04:00
Benjamin Peterson 10e4b2545e merge 3.4 (closes #22518) 2014-09-29 18:53:58 -04:00
Benjamin Peterson 2b76ce6d27 merge 3.3 (closes #22518) 2014-09-29 18:50:06 -04:00
Benjamin Peterson a1c1be4e03 cleanup overflowing handling in unicode_decode_call_errorhandler and unicode_encode_ucs1 (closes #22518) 2014-09-29 18:18:57 -04:00
Serhiy Storchaka 20b39b27d9 Removed redundant casts to `char *`.
Corresponding functions now accept `const char *` (issue #1772673).
2014-09-28 11:27:24 +03:00
Serhiy Storchaka d8a1447c99 Issue #22215: Now ValueError is raised instead of TypeError when str or bytes
argument contains not permitted null character or byte.
2014-09-06 20:07:17 +03:00
Victor Stinner 8f4ec8d3ef Issue #22290: PyObject_Call() now fails with an assertion error when called
with an exception set. This new assertion helps to understand if the exception
was already set before calling the function or raised by the function.
2014-09-05 01:10:29 +02:00
Benjamin Peterson 48ad7c0b01 use __qualname__ to compute bound method repr (closes #21389)
Patch from Steven Barker.
2014-08-20 18:41:57 -05:00
Victor Stinner 049e509a9f Issue #22207: Fix "comparison between signed and unsigned integers" warning in
test checking for integer overflow on Py_ssize_t type: cast explicitly to
size_t.
2014-08-17 22:20:00 +02:00