Meador Inge
3388060127
Issue #13629 : Renumber the tokens in token.h to match the _PyParser_TokenNames indexes.
14 years ago
Gregory P. Smith
63e6c3222f
Consolidate the occurrances of the prime used as the multiplier when hashing
to a single #define instead of having several copies in several files.
This excludes the Modules/ tree (datetime and expat both have a copy
for their own purposes with no need for it to be the same).
14 years ago
Benjamin Peterson
d5890c8db5
add str.casefold() ( closes #13752 )
14 years ago
Benjamin Peterson
527c622926
make YieldFrom its own distinct from Yield ( closes #13780 )
14 years ago
Nick Coghlan
76e1bb0ef9
Fix indenting
14 years ago
Amaury Forgeot d'Arc
77b1ecf0ad
Silence compilation warnings on Windows
14 years ago
Nick Coghlan
1f7ce62bd6
Implement PEP 380 - 'yield from' ( closes #11682 )
14 years ago
Benjamin Peterson
b2bf01d824
use full unicode mappings for upper/lower/title case ( #12736 )
Also broaden the category of characters that count as lowercase/uppercase.
14 years ago
Victor Stinner
3fe553160c
Add a new PyUnicode_Fill() function
It is faster than the unicode_fill() function which was implemented in
formatter_unicode.c.
14 years ago
Antoine Pitrou
5b62942074
Issue #13577 : Built-in methods and functions now have a __qualname__.
Patch by sbt.
14 years ago
Victor Stinner
80bc72d5a2
fix PyCompactUnicodeObject doc (test)
14 years ago
Victor Stinner
52e2cc8604
backout 7876cd49300d: Move PyUnicode_WCHAR_KIND outside PyUnicode_Kind enum
14 years ago
Victor Stinner
0ba5af20c0
Move PyUnicode_WCHAR_KIND outside PyUnicode_Kind enum
14 years ago
Victor Stinner
1b57967b96
Issue #13560 : Locale codec functions use the classic "errors" parameter,
instead of surrogateescape
So it would be possible to support more error handlers later.
14 years ago
Victor Stinner
f2ea71fcc8
Issue #13560 : Add PyUnicode_EncodeLocale()
* Use PyUnicode_EncodeLocale() in time.strftime() if wcsftime() is not
available
* Document my last changes in Misc/NEWS
14 years ago
Victor Stinner
af02e1c85a
Add PyUnicode_DecodeLocaleAndSize() and PyUnicode_DecodeLocale()
* PyUnicode_DecodeLocaleAndSize() and PyUnicode_DecodeLocale() decode a string
from the current locale encoding
* _Py_char2wchar() writes an "error code" in the size argument to indicate
if the function failed because of memory allocation failure or because of a
decoding error. The function doesn't write the error message directly to
stderr.
* Fix time.strftime() (if wcsftime() is missing): decode strftime() result
from the current locale encoding, not from the filesystem encoding.
14 years ago
Antoine Pitrou
093ce9cd8c
Issue #6695 : Full garbage collection runs now clear the freelist of set objects.
Initial patch by Matthias Troffaes.
14 years ago
Benjamin Peterson
bfebb7b54a
improve abstract property support ( closes #11610 )
Thanks to Darren Dale for patch.
14 years ago
Antoine Pitrou
9d57481f04
Issue #13577 : various kinds of descriptors now have a __qualname__ attribute.
Patch by sbt.
14 years ago
Victor Stinner
16e6a80923
PyUnicode_Resize(): warn about canonical representation
Call also directly unicode_resize() in unicodeobject.c
14 years ago
Victor Stinner
b0a82a6a7f
Fix PyUnicode_Resize() for compact string: leave the string unchanged on error
Fix also PyUnicode_Resize() doc
14 years ago
Victor Stinner
bf6e560d0c
Make PyUnicode_Copy() private => _PyUnicode_Copy()
Undocument the function.
Make also decode_utf8_errors() as private (static).
14 years ago
Victor Stinner
7a9105a380
resize_copy() now supports legacy ready strings
14 years ago
Victor Stinner
24c74be9a3
PyUnicode_IS_ASCII() macro ensures that the string is ready
It has no sense to check if a not ready string is ASCII or not.
14 years ago
Barry Warsaw
9f57135465
- Issue #11147 : Fix an unused argument in _Py_ANNOTATE_MEMORY_ORDER. (Fix
given by Campbell Barton).
14 years ago
Victor Stinner
551ac95733
Py_UNICODE_HIGH_SURROGATE() and Py_UNICODE_LOW_SURROGATE() macros
And use surrogates macros everywhere in unicodeobject.c
14 years ago
Jesus Cea
6d47db31f0
Closes issue #13488 : Some old preprocessors have problem with #define not in the first column
14 years ago
Victor Stinner
0fdfceb782
Issue #12567 : The curses module uses Unicode functions for Unicode arguments
when it is linked to the ncurses library. It encodes also Unicode strings to
the locale encoding instead of UTF-8.
14 years ago
Antoine Pitrou
86a36b500a
PEP 3155 / issue #13448 : Qualified name for classes and functions.
14 years ago
Antoine Pitrou
6dd381eb62
Issue #12328 : Under Windows, refactor handling of Ctrl-C events and
make _multiprocessing.win32.WaitForMultipleObjects interruptible when
the wait_flag parameter is false. Patch by sbt.
14 years ago
Antoine Pitrou
ce4a9da705
Issue #13411 : memoryview objects are now hashable when the underlying object is hashable.
14 years ago
Victor Stinner
f3ae6208c7
PyUnicode_GET_SIZE() checks that PyUnicode_AsUnicode() succeed
using an assertion
14 years ago
Victor Stinner
77faf69ca1
_PyUnicode_CheckConsistency() also checks maxchar maximum value,
not only its minimum value
14 years ago
Victor Stinner
9343999597
Fix PyUnicode_CopyCharacters() doc
14 years ago
Victor Stinner
7c8bbbbb0c
Ensure that Py_UCS4 is 32 bits and Py_UCS2 is 16 bits
14 years ago
Petri Lehtinen
8d40f16a60
Issue #13338 : Handle all enumerations in _Py_ANNOTATE_MEMORY_ORDER
This allows compiling extension modules with -Wswitch-enum on gcc.
Initial patch by Floris Bruynooghe.
14 years ago
Antoine Pitrou
f34a0cdc6c
Issue #10227 : Add an allocation cache for a single slice object.
Patch by Stefan Behnel.
14 years ago
Victor Stinner
6f9568bb1f
Fix misused of "PyUnicodeObject" structure name in unicodeobject.h
14 years ago
Antoine Pitrou
9a812cbc89
Issue #13389 : Full garbage collection passes now clear the freelists for
list and dict objects. They already cleared other freelists in the
interpreter.
14 years ago
Martin v. Löwis
1db7c13be1
Port encoders from Py_UNICODE API to unicode object API.
14 years ago
Martin v. Löwis
d10759f6ed
Make _PyUnicode_FromId return borrowed references.
http://mail.python.org/pipermail/python-dev/2011-November/114347.html
15 years ago
Victor Stinner
e30c0a1014
Fix gdb/libpython.py for not ready Unicode strings
_PyUnicode_CheckConsistency() checks also hash and length value for not ready
Unicode strings.
15 years ago
Victor Stinner
7931d9a951
Replace PyUnicodeObject type by PyObject
* _PyUnicode_CheckConsistency() now takes a PyObject* instead of void*
* Remove now useless casts to PyObject*
15 years ago
Martin v. Löwis
23e275b3ad
Port UCS1 and charmap codecs to new API.
15 years ago
Nick Coghlan
de31b191e5
Issue 1294232: Fix errors in metaclass calculation affecting some cases of metaclass inheritance. Patch by Daniel Urban.
15 years ago
Martin v. Löwis
0d3072e98d
Drop Py_UCS4_ functions. Closes #13246 .
15 years ago
Victor Stinner
9db1a8b69f
Replace PyUnicodeObject* by PyObject* where it was irrevelant
A Unicode string can now be a PyASCIIObject, PyCompactUnicodeObject or
PyUnicodeObject. Aliasing a PyASCIIObject* or PyCompactUnicodeObject* to
PyUnicodeObject* is wrong
15 years ago
Ezio Melotti
931b8aac80
#12753 : Add support for Unicode name aliases and named sequences.
15 years ago
Victor Stinner
55c7e00fc0
Simplify _PyUnicode_COMPACT_DATA() macro
15 years ago
Victor Stinner
3a50e7056e
Issue #12281 : Rewrite the MBCS codec to handle correctly replace and ignore
error handlers on all Windows versions. The MBCS codec is now supporting all
error handlers, instead of only replace to encode and ignore to decode.
15 years ago