Serhiy Storchaka
9a953dbb34
Issue #28808 : PyUnicode_CompareWithASCIIString() now never raises exceptions.
2016-12-06 00:17:45 +02:00
Serhiy Storchaka
419967b832
Issue #28808 : PyUnicode_CompareWithASCIIString() now never raises exceptions.
2016-12-06 00:13:34 +02:00
Nick Coghlan
19d246745d
Issue #23722 : improve __classcell__ compatibility
...
Handling zero-argument super() in __init_subclass__ and
__set_name__ involved moving __class__ initialisation to
type.__new__. This requires cooperation from custom
metaclasses to ensure that the new __classcell__ entry
is passed along appropriately.
The initial implementation of that change resulted in abruptly
broken zero-argument super() support in metaclasses that didn't
adhere to the new requirements (such as Django's metaclass for
Model definitions).
The updated approach adopted here instead emits a deprecation
warning for those cases, and makes them work the same way they
did in Python 3.5.
This patch also improves the related class machinery documentation
to cover these details and to include more reader-friendly
cross-references and index entries.
2016-12-05 16:47:55 +10:00
Serhiy Storchaka
9ec07721f4
Issue #28797 : Modifying the class __dict__ inside the __set_name__ method of
...
a descriptor that is used inside that class no longer prevents calling the
__set_name__ method of other descriptors.
2016-11-29 09:54:17 +02:00
Victor Stinner
f7d199ff32
Fix _PyGen_yf()
...
Issue #28782 : Fix a bug in the implementation ``yield from`` when checking
if the next instruction is YIELD_FROM. Regression introduced by WORDCODE
(issue #26647 ).
Reviewed by Serhiy Storchaka and Yury Selivanov.
2016-11-24 22:33:01 +01:00
Serhiy Storchaka
ac0720eaa4
Issue #28760 : Clean up and fix comments in PyUnicode_AsUnicodeEscapeString().
...
Patch by Xiang Zhang.
2016-11-21 11:46:51 +02:00
Serhiy Storchaka
06515833fe
Replaced outdated macros _PyUnicode_AsString and _PyUnicode_AsStringAndSize
...
with PyUnicode_AsUTF8 and PyUnicode_AsUTF8AndSize.
2016-11-20 09:13:07 +02:00
Yury Selivanov
41782e4970
Issue #28721 : Fix asynchronous generators aclose() and athrow()
2016-11-16 18:16:17 -05:00
Serhiy Storchaka
a83a6a3275
Issue #28701 : _PyUnicode_EqualToASCIIId and _PyUnicode_EqualToASCIIString now
...
require ASCII right argument and assert this condition in debug build.
2016-11-16 20:02:44 +02:00
Serhiy Storchaka
df66b9c425
Fixed an off-by-one error in _PyUnicode_EqualToASCIIString (issue #28701 ).
2016-11-16 16:12:56 +02:00
Serhiy Storchaka
292dd1b2ad
Fixed an off-by-one error in _PyUnicode_EqualToASCIIString (issue #28701 ).
2016-11-16 16:12:34 +02:00
Serhiy Storchaka
dddec81b2d
Issue #21449 : Removed private function _PyUnicode_CompareWithId.
2016-11-16 15:56:27 +02:00
Serhiy Storchaka
fab6acd9f5
Issue #28701 : Replace _PyUnicode_CompareWithId with _PyUnicode_EqualToASCIIId.
...
The latter function is more readable, faster and doesn't raise exceptions.
Based on patch by Xiang Zhang.
2016-11-16 15:41:11 +02:00
Serhiy Storchaka
f5894dd646
Issue #28701 : Replace _PyUnicode_CompareWithId with _PyUnicode_EqualToASCIIId.
...
The latter function is more readable, faster and doesn't raise exceptions.
Based on patch by Xiang Zhang.
2016-11-16 15:40:39 +02:00
Serhiy Storchaka
3b73ea1278
Issue #28701 : Replace PyUnicode_CompareWithASCIIString with _PyUnicode_EqualToASCIIString.
...
The latter function is more readable, faster and doesn't raise exceptions.
2016-11-16 10:19:20 +02:00
Serhiy Storchaka
f4934ea77d
Issue #28701 : Replace PyUnicode_CompareWithASCIIString with _PyUnicode_EqualToASCIIString.
...
The latter function is more readable, faster and doesn't raise exceptions.
2016-11-16 10:17:58 +02:00
Serhiy Storchaka
babe4f8e5e
Issue #28648 : Fixed crash in Py_DecodeLocale() in debug build on Mac OS X
...
when decode astral characters.
2016-11-12 14:36:02 +02:00
Serhiy Storchaka
6b4b6e956e
Issue #28648 : Fixed crash in Py_DecodeLocale() in debug build on Mac OS X
...
when decode astral characters.
2016-11-12 14:35:46 +02:00
Serhiy Storchaka
84293aff9f
Issue #28648 : Fixed crash in Py_DecodeLocale() in debug build on Mac OS X
...
when decode astral characters.
2016-11-12 14:29:48 +02:00
Serhiy Storchaka
b626643734
Issue #28648 : Fixed crash in Py_DecodeLocale() in debug build on Mac OS X
...
when decode astral characters.
2016-11-12 14:28:06 +02:00
Yury Selivanov
6c10650617
Merge 3.5 (issue #27942 )
2016-11-09 09:43:08 -05:00
Yury Selivanov
d2fd3599ab
ssue #27942 : Fix memory leak in codeobject.c
2016-11-09 09:42:14 -05:00
Yury Selivanov
29310c47a7
Issue #28003 : Make WrappedVal, ASend and AThrow GC types
2016-11-08 19:46:22 -05:00
Yury Selivanov
49ffdf6bb2
Merge 3.5
2016-11-08 19:19:52 -05:00
Yury Selivanov
33499b7eed
genobject: Remove unnecessary tp_free slots from aiter_wrapper and coro_wrapper
2016-11-08 19:19:28 -05:00
Steve Dower
78057b4159
Closes #27781 : Removes special cases for the experimental aspect of PEP 529
2016-11-06 19:35:08 -08:00
Benjamin Peterson
3bd7900155
merge 3.5
2016-11-06 13:01:15 -08:00
Benjamin Peterson
db87c99444
make sure dict view types are initialized
2016-11-06 13:01:07 -08:00
Serhiy Storchaka
60e49aa756
Issue #23996 : Added _PyGen_SetStopIterationValue for safe raising
...
StopIteration with value. More safely handle non-normalized exceptions
in -_PyGen_FetchStopIterationValue.
2016-11-06 18:47:03 +02:00
Serhiy Storchaka
24411f8a8d
Issue #23996 : Added _PyGen_SetStopIterationValue for safe raising
...
StopIteration with value. More safely handle non-normalized exceptions
in -_PyGen_FetchStopIterationValue.
2016-11-06 18:44:42 +02:00
Serhiy Storchaka
f0b311bd73
Issue #28123 : _PyDict_GetItem_KnownHash() now can raise an exception as
...
PyDict_GetItemWithError(). Patch by Xiang Zhang.
2016-11-06 13:18:24 +02:00
INADA Naoki
93f26f794d
Issue #28583 : PyDict_SetDefault didn't combine split table when needed.
...
Patch by Xiang Zhang.
2016-11-02 18:45:16 +09:00
Eric V. Smith
5646648678
Issue 28128: Print out better error/warning messages for invalid string escapes. Backport to 3.6.
2016-10-31 14:46:26 -04:00
Serhiy Storchaka
7f0514ad54
Backed out changeset 6b88dfc7b25d
2016-10-31 20:14:05 +02:00
Serhiy Storchaka
7984bff52a
Issue #28385 : An error message when non-empty format spec is passed to
...
object.__format__ now contains the name of actual type.
2016-10-30 19:37:46 +02:00
Serhiy Storchaka
d1af5effc2
Issue #28385 : An error message when non-empty format spec is passed to
...
object.__format__ now contains the name of actual type.
2016-10-30 19:33:54 +02:00
Serhiy Storchaka
998c9cdd42
Issue #28561 : Clean up UTF-8 encoder: remove dead code, update comments, etc.
...
Patch by Xiang Zhang.
2016-10-30 18:25:27 +02:00
Serhiy Storchaka
b7d14a09c2
Merge from 3.5.
2016-10-30 17:25:45 +02:00
Serhiy Storchaka
0438683939
Backed out changeset 9f7505019767 (issue #27275 ).
2016-10-30 17:17:24 +02:00
Serhiy Storchaka
d76d8bfee1
Issue #28199 : Microoptimized dict resizing. Based on patch by Naoki Inada.
2016-10-29 10:49:43 +03:00
Yury Selivanov
684ef2c888
Issue #28544 : Pass `PyObject*` to _PyDict_Pop, not `PyDictObject*`
2016-10-28 19:01:21 -04:00
Serhiy Storchaka
0093907f0e
Issue #28426 : Deprecated undocumented functions PyUnicode_AsEncodedObject(),
...
PyUnicode_AsDecodedObject(), PyUnicode_AsDecodedUnicode() and
PyUnicode_AsEncodedUnicode().
2016-10-27 21:05:49 +03:00
INADA Naoki
b1152be2de
Issue #28509 : dict.update() no longer allocate unnecessary large memory
2016-10-27 19:26:50 +09:00
Serhiy Storchaka
1faf9025b5
Issue #27275 : Fixed implementation of pop() and popitem() methods in
...
subclasses of accelerated OrderedDict.
2016-10-25 15:36:56 +03:00
Serhiy Storchaka
4832580596
Issue #27275 : Fixed implementation of pop() and popitem() methods in
...
subclasses of accelerated OrderedDict.
2016-10-25 15:33:23 +03:00
Serhiy Storchaka
c8bc3d1c07
Issue #28408 : Fixed a leak and remove redundant code in _PyUnicodeWriter_Finish().
...
Patch by Xiang Zhang.
2016-10-25 13:23:56 +03:00
Serhiy Storchaka
c4a3e90aa8
Issue #28426 : Fixed potential crash in PyUnicode_AsDecodedObject() in debug build.
2016-10-25 10:17:33 +03:00
Serhiy Storchaka
839023f12c
Issue #28426 : Fixed potential crash in PyUnicode_AsDecodedObject() in debug build.
2016-10-25 10:13:43 +03:00
Serhiy Storchaka
77eede35fc
Issue #28426 : Fixed potential crash in PyUnicode_AsDecodedObject() in debug build.
2016-10-25 10:07:51 +03:00
Serhiy Storchaka
d5d32d2127
Issue #28214 : Improved exception reporting for problematic __set_name__
...
attributes.
2016-10-21 17:13:31 +03:00