Stefan Krah
1649c1b33a
Issue #14181 : Preserve backwards compatibility for getbufferprocs that a) do
not adhere to the new documentation and b) manage to clobber view->obj before
returning failure.
14 years ago
Benjamin Peterson
400a968dfc
remove f_yieldfrom access from Python ( closes #13970 )
14 years ago
Stefan Krah
4e99a315b7
Issue #14181 : Allow memoryview construction from an object that uses the
getbuffer redirection scheme.
14 years ago
Victor Stinner
c9590ad745
Close #14085 : remove assertions from PyUnicode_WRITE macro
Add checks in PyUnicode_WriteChar() and convert PyUnicode_New() assertion to a
test raising a Python exception.
14 years ago
Antoine Pitrou
e965d97ed1
Issue #13521 : dict.setdefault() now does only one lookup for the given key, making it "atomic" for many purposes.
Patch by Filip Gruszczyński.
14 years ago
Nick Coghlan
ab7bf2143e
Close issue #6210 : Implement PEP 409
14 years ago
Ezio Melotti
cda6b6d60d
#14081 : The sep and maxsplit parameter to str.split, bytes.split, and bytearray.split may now be passed as keyword arguments.
14 years ago
Stefan Krah
9a2d99e28a
- Issue #10181 : New memoryview implementation fixes multiple ownership
and lifetime issues of dynamically allocated Py_buffer members (#9990 )
as well as crashes (#8305 , #7433 ). Many new features have been added
(See whatsnew/3.3), and the documentation has been updated extensively.
The ndarray test object from _testbuffer.c implements all aspects of
PEP-3118, so further development towards the complete implementation
of the PEP can proceed in a test-driven manner.
Thanks to Nick Coghlan, Antoine Pitrou and Pauli Virtanen for review
and many ideas.
- Issue #12834 : Fix incorrect results of memoryview.tobytes() for
non-contiguous arrays.
- Issue #5231 : Introduce memoryview.cast() method that allows changing
format and shape without making a copy of the underlying memory.
14 years ago
Victor Stinner
6f73874edd
Close #14095 : type.__new__() doesn't remove __qualname__ key from the class
dict anymore if the key is present. Reject also non-string qualified names.
And fix reference leaks in type.__new__().
14 years ago
Victor Stinner
b0800dc53b
Oops, revert unwanted changes
14 years ago
Victor Stinner
abc649ddbe
Issue #14107 : fix bigmem tests on str.capitalize(), str.swapcase() and
str.title(). Compute correctly how much memory is required for the test
(memuse).
14 years ago
Antoine Pitrou
842c0f17eb
Fix compilation error under Windows (and warnings too).
14 years ago
Victor Stinner
90f50d4df9
Issue #13706 : Fix format(float, "n") for locale with non-ASCII decimal point (e.g. ps_aF)
14 years ago
Victor Stinner
41a863cb81
Issue #13706 : Fix format(int, "n") for locale with non-ASCII thousands separator
* Decode thousands separator and decimal point using PyUnicode_DecodeLocale()
(from the locale encoding), instead of decoding them implicitly from latin1
* Remove _PyUnicode_InsertThousandsGroupingLocale(), it was not used
* Change _PyUnicode_InsertThousandsGrouping() API to return the maximum
character if unicode is NULL
* Replace MIN/MAX macros by Py_MIN/Py_MAX
* stringlib/undef.h undefines STRINGLIB_IS_UNICODE
* stringlib/localeutil.h only supports Unicode
14 years ago
Victor Stinner
b429d3b09c
Fix doc of an internal function: unicode_write_cstr()
14 years ago
Antoine Pitrou
ba6bafcfbe
Fix compile failure under Windows
14 years ago
Victor Stinner
c516610f0b
Optimize str%arg for number formats: %i, %d, %u, %x, %p
Write a specialized function to write an ASCII/latin1 C char* string into a
Python Unicode string.
14 years ago
Victor Stinner
99d7ad0bb0
Micro-optimize computation of maxchar in PyUnicode_TransformDecimalToASCII()
14 years ago
Victor Stinner
da79e632c4
Micro-optimize unicode_expandtabs(): use FILL() macro to write N spaces
14 years ago
Victor Stinner
15e9ed299c
PyUnicode_New() and unicode_putchar() check for MAX_UNICODE maximum (U+10FFFF)
14 years ago
Benjamin Peterson
69e9727657
ensure no one tries to hash things before the random seed is found
14 years ago
Benjamin Peterson
71f660e00f
update to Unicode 6.1
14 years ago
Georg Brandl
16fa2a1097
Forgot the "empty string -> hash == 0" special case for strings.
14 years ago
Georg Brandl
2daf6ae249
Issue #13703 : add a way to randomize the hash values of basic types (str, bytes, datetime)
in order to make algorithmic complexity attacks on (e.g.) web apps much more complicated.
The environment variable PYTHONHASHSEED and the new command line flag -R control this
behavior.
14 years ago
Benjamin Peterson
006c5a2235
check for NULL to fix segfault
14 years ago
Benjamin Peterson
23d7f12ffb
use new generic __dict__ descriptor implementations
14 years ago
Benjamin Peterson
8eb1269c34
add generic implementation of a __dict__ descriptor for C types
14 years ago
Benjamin Peterson
b900d6a78c
initialize __dict__ if needed
14 years ago
Benjamin Peterson
2cf936fe7a
use defaults
14 years ago
Benjamin Peterson
496c53d83e
use Py_CLEAR
14 years ago
Benjamin Peterson
01d7eba316
allow arbitrary attributes on classmethod and staticmethod ( closes #14051 )
14 years ago
Antoine Pitrou
4b3c7846c9
Fix indentation
14 years ago
Antoine Pitrou
37784ba5c0
Issue #13020 : Fix a reference leak when allocating a structsequence object fails.
Patch by Suman Saha.
14 years ago
Victor Stinner
cbe01342bc
Issue #13913 : normalize utf-8 codec name in UTF-8 decoder
14 years ago
Benjamin Peterson
efe7c9d4d7
this is only a borrowed ref in Brett's branch
14 years ago
Victor Stinner
d1cd99b533
Backout d2c1521ad0a1: _Py_IDENTIFIER() uses UTF-8 again
14 years ago
Benjamin Peterson
2f9c71bbba
bltinmod is borrowed, so it shouldn't be decrefed
14 years ago
Victor Stinner
d446d8e09a
_Py_Identifier are always ASCII strings
14 years ago
Benjamin Peterson
90b13583bc
put returns on their own lines
14 years ago
Benjamin Peterson
2652d2570e
ready types returned from PyType_FromSpec
14 years ago
Benjamin Peterson
e28108cbd7
adjust declaration
14 years ago
Antoine Pitrou
1334884ff2
Issue #13848 : open() and the FileIO constructor now check for NUL characters in the file name.
Patch by Hynek Schlawack.
14 years ago
Mark Dickinson
261896b559
Issue #13889 : Add missing _Py_SET_53BIT_PRECISION_* calls around uses of dtoa.c functions in float round.
14 years ago
Georg Brandl
beca27a394
Fix #13834 : strip() strips leading and trailing whitespace.
14 years ago
Benjamin Peterson
ce79852077
use the static identifier api for looking up special methods
I had to move the static identifier code from unicodeobject.h to object.h in
order for this to work.
14 years ago
Antoine Pitrou
ac456a1839
Fix some of the remaining test_capi leaks
14 years ago
Antoine Pitrou
8b0a74e936
Fix some of the remaining test_capi refleaks
14 years ago
Antoine Pitrou
55f217f22d
Fix refleaks in test_capi
(this was easier than I thought!)
14 years ago
Antoine Pitrou
1c7ade5284
Fix leaking a RuntimeError objects when creating sub-interpreters
14 years ago
Benjamin Peterson
eea4846d23
don't ready in case_operation, since most callers do it themselves
14 years ago