Serhiy Storchaka
b1a1619bf0
Issue #29000 : Fixed bytes formatting of octals with zero padding in alternate
form.
9 years ago
Xavier de Gaye
76febd0792
Issue #26919 : On Android, operating system data is now always encoded/decoded
to/from UTF-8, instead of the locale encoding to avoid inconsistencies with
os.fsencode() and os.fsdecode() which are already using UTF-8.
9 years ago
Victor Stinner
ccda5c41df
Fix a memory leak in split-table dictionaries
Issue #28147 : Fix a memory leak in split-table dictionaries: setattr() must not
convert combined table into split table.
Patch written by INADA Naoki.
(grafted from 85be9dcc16 )
9 years ago
Victor Stinner
3d3f264849
Fix a memory leak in split-table dictionaries
Issue #28147 : Fix a memory leak in split-table dictionaries: setattr() must not
convert combined table into split table.
Patch written by INADA Naoki.
9 years ago
Serhiy Storchaka
49010ee323
Revert changeset 1f31bf3f76f5 (issue5322) except tests.
9 years ago
Martin Panter
186b204997
Fix typos in comment and documentation
9 years ago
Serhiy Storchaka
419967b832
Issue #28808 : PyUnicode_CompareWithASCIIString() now never raises exceptions.
9 years ago
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.
9 years ago
Serhiy Storchaka
5adfac2c1b
Issue #5322 : Fixed setting __new__ to a PyCFunction inside Python code.
Original patch by Andreas Stührk.
9 years ago
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.
9 years ago
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.
9 years ago
INADA Naoki
2c5a830f2a
Issue #28731 : Optimize _PyDict_NewPresized() to create correct size dict.
Improve speed of dict literal with constant keys up to 30%.
9 years ago
Serhiy Storchaka
ac0720eaa4
Issue #28760 : Clean up and fix comments in PyUnicode_AsUnicodeEscapeString().
Patch by Xiang Zhang.
9 years ago
Serhiy Storchaka
06515833fe
Replaced outdated macros _PyUnicode_AsString and _PyUnicode_AsStringAndSize
with PyUnicode_AsUTF8 and PyUnicode_AsUTF8AndSize.
9 years ago
Yury Selivanov
41782e4970
Issue #28721 : Fix asynchronous generators aclose() and athrow()
9 years ago
Serhiy Storchaka
a83a6a3275
Issue #28701 : _PyUnicode_EqualToASCIIId and _PyUnicode_EqualToASCIIString now
require ASCII right argument and assert this condition in debug build.
9 years ago
Serhiy Storchaka
292dd1b2ad
Fixed an off-by-one error in _PyUnicode_EqualToASCIIString (issue #28701 ).
9 years ago
Serhiy Storchaka
dddec81b2d
Issue #21449 : Removed private function _PyUnicode_CompareWithId.
9 years ago
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.
9 years ago
Serhiy Storchaka
f4934ea77d
Issue #28701 : Replace PyUnicode_CompareWithASCIIString with _PyUnicode_EqualToASCIIString.
The latter function is more readable, faster and doesn't raise exceptions.
9 years ago
Serhiy Storchaka
b626643734
Issue #28648 : Fixed crash in Py_DecodeLocale() in debug build on Mac OS X
when decode astral characters.
9 years ago
Yury Selivanov
d2fd3599ab
ssue #27942 : Fix memory leak in codeobject.c
9 years ago
Yury Selivanov
29310c47a7
Issue #28003 : Make WrappedVal, ASend and AThrow GC types
9 years ago
Yury Selivanov
33499b7eed
genobject: Remove unnecessary tp_free slots from aiter_wrapper and coro_wrapper
9 years ago
Steve Dower
78057b4159
Closes #27781 : Removes special cases for the experimental aspect of PEP 529
9 years ago
Benjamin Peterson
db87c99444
make sure dict view types are initialized
9 years ago
Serhiy Storchaka
24411f8a8d
Issue #23996 : Added _PyGen_SetStopIterationValue for safe raising
StopIteration with value. More safely handle non-normalized exceptions
in -_PyGen_FetchStopIterationValue.
9 years ago
Serhiy Storchaka
f0b311bd73
Issue #28123 : _PyDict_GetItem_KnownHash() now can raise an exception as
PyDict_GetItemWithError(). Patch by Xiang Zhang.
9 years ago
INADA Naoki
93f26f794d
Issue #28583 : PyDict_SetDefault didn't combine split table when needed.
Patch by Xiang Zhang.
9 years ago
Eric V. Smith
5646648678
Issue 28128: Print out better error/warning messages for invalid string escapes. Backport to 3.6.
9 years ago
Serhiy Storchaka
7f0514ad54
Backed out changeset 6b88dfc7b25d
9 years ago
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.
9 years ago
Serhiy Storchaka
998c9cdd42
Issue #28561 : Clean up UTF-8 encoder: remove dead code, update comments, etc.
Patch by Xiang Zhang.
9 years ago
Serhiy Storchaka
0438683939
Backed out changeset 9f7505019767 (issue #27275 ).
9 years ago
Serhiy Storchaka
d76d8bfee1
Issue #28199 : Microoptimized dict resizing. Based on patch by Naoki Inada.
9 years ago
Yury Selivanov
684ef2c888
Issue #28544 : Pass `PyObject*` to _PyDict_Pop, not `PyDictObject*`
9 years ago
Serhiy Storchaka
0093907f0e
Issue #28426 : Deprecated undocumented functions PyUnicode_AsEncodedObject(),
PyUnicode_AsDecodedObject(), PyUnicode_AsDecodedUnicode() and
PyUnicode_AsEncodedUnicode().
9 years ago
INADA Naoki
b1152be2de
Issue #28509 : dict.update() no longer allocate unnecessary large memory
9 years ago
Serhiy Storchaka
4832580596
Issue #27275 : Fixed implementation of pop() and popitem() methods in
subclasses of accelerated OrderedDict.
9 years ago
Serhiy Storchaka
c8bc3d1c07
Issue #28408 : Fixed a leak and remove redundant code in _PyUnicodeWriter_Finish().
Patch by Xiang Zhang.
9 years ago
Serhiy Storchaka
77eede35fc
Issue #28426 : Fixed potential crash in PyUnicode_AsDecodedObject() in debug build.
9 years ago
Serhiy Storchaka
d5d32d2127
Issue #28214 : Improved exception reporting for problematic __set_name__
attributes.
9 years ago
Serhiy Storchaka
467ab194fc
Issue #28410 : Added _PyErr_FormatFromCause() -- the helper for raising
new exception with setting current exception as __cause__.
_PyErr_FormatFromCause(exception, format, args...) is equivalent to Python
raise exception(format % args) from sys.exc_info()[1]
9 years ago
Benjamin Peterson
8d761ff045
remove extra PyErr_Format arguments ( closes #28454 )
Patch from Xiang Zhang.
9 years ago
Christian Heimes
5cade88ac1
Check return value of _PyDict_SetItemId()
9 years ago
Victor Stinner
ebe17e0347
Fix _Py_normalize_encoding() command
It's not exactly the same than encodings.normalize_encoding(): the C function
also converts to lowercase.
9 years ago
Benjamin Peterson
b329e1bb5b
va_end vargs2 once ( closes #28417 )
9 years ago
doko@ubuntu.com
de69ee71e2
- dictobject.c: Make dict_merge symbol a static symbol
9 years ago
Serhiy Storchaka
49f5cdde1a
Issue #28183 : Optimize and cleanup dict iteration.
9 years ago
Serhiy Storchaka
9c0e1f83af
Issue #28379 : Added sanity checks and tests for PyUnicode_CopyCharacters().
Patch by Xiang Zhang.
9 years ago