Serhiy Storchaka
cf095f8e0f
Issue #16761 : Raise TypeError when int() or long() called with base argument only.
2012-12-28 09:31:59 +02:00
Antoine Pitrou
d38c990bb7
Issue #16602 : When a weakref's target was part of a long deallocation chain, the object could remain reachable through its weakref even though its refcount had dropped to zero.
...
Thanks to Eugene Toder for diagnosing and reporting the issue.
2012-12-08 21:15:26 +01:00
Mark Dickinson
115bc79df8
Issue #9742 : Sneaky fix for build failure on Solaris 9.
2012-11-17 20:18:52 +00:00
Antoine Pitrou
e3ae321222
Issue #15379 : Fix passing of non-BMP characters as integers for the charmap decoder (already working as unicode strings).
...
Patch by Serhiy Storchaka.
2012-11-17 21:14:58 +01:00
Antoine Pitrou
b704eab599
Issue #16453 : Fix equality testing of dead weakref objects.
...
Also add tests for hashing.
2012-11-11 19:36:51 +01:00
Christian Heimes
146a5fead2
Fix compilation on Windows
2012-11-03 23:07:59 +01:00
Ezio Melotti
67dc4a87fc
#8401 : assigning an int to a bytearray slice (e.g. b[3:4] = 5) now raises an error.
2012-11-03 21:10:45 +02:00
Benjamin Peterson
47fa4d54e8
avoid a function call with redundant checks for dict size
2012-10-31 14:22:12 -04:00
Benjamin Peterson
0ec820fc5f
only fast-path fromkeys() when the constructor returns a empty dict ( closes #16345 )
2012-10-31 14:05:55 -04:00
Benjamin Peterson
6da3ed63d8
initialize more global type objects ( closes #16369 )
2012-10-30 23:21:10 -04:00
Mark Dickinson
75d3600466
Issue #14700 : Fix buggy overflow checks for large precision and width in new-style and old-style formatting.
2012-10-28 10:00:46 +00:00
Chris Jerdonek
ad4b000179
Issue #14783 : Backport changes from 3.2.
2012-10-07 20:37:54 -07:00
Mark Dickinson
218a8ab5eb
Issues #16029 , #16030 : Fix pickling and repr of large xranges.
2012-09-28 20:36:36 +01:00
Christian Heimes
47770ed914
Fixed memory leak in error branch of object_repr which may leak a reference to mod when type_name returns NULL. CID 715371
2012-09-10 16:57:36 +02:00
Christian Heimes
4e80eea60e
Fixed possible reference leak to mod when type_name() returns NULL
2012-09-10 03:00:14 +02:00
Christian Heimes
074ebced1b
PyTuple_Pack() was missing va_end() in its error branch which lead to a resource leak.
2012-09-10 02:54:51 +02:00
Antoine Pitrou
58098a77e6
Issue #13992 : The trashcan mechanism is now thread-safe. This eliminates
...
sporadic crashes in multi-thread programs when several long deallocator
chains ran concurrently and involved subclasses of built-in container
types.
Because of this change, a couple extension modules compiled for 2.7.4
(those which use the trashcan mechanism, despite it being undocumented)
will not be loadable by 2.7.3 and earlier. However, extension modules
compiled for 2.7.3 and earlier will be loadable by 2.7.4.
2012-09-06 00:59:49 +02:00
Benjamin Peterson
23d49d3e7e
use the stricter PyMapping_Check ( closes #15801 )
2012-08-28 17:55:35 -04:00
Antoine Pitrou
c5bef75c77
Issue #15604 : Update uses of PyObject_IsTrue() to check for and handle errors correctly.
...
Patch by Serhiy Storchaka.
2012-08-15 23:16:51 +02:00
Antoine Pitrou
715a63b783
Issue #14579 : Fix error handling bug in the utf-16 decoder.
...
Patch by Serhiy Storchaka.
2012-07-21 00:52:06 +02:00
Benjamin Peterson
7d8a2e41a0
allow any number to be returned from __length_hint__ ( closes #15354 )
2012-07-14 17:53:55 -07:00
Gregory P. Smith
b2ac4d693a
Fixes issue #12268 for file readline, readlines and read() and readinto methods.
...
They no longer lose data when an underlying read system call is interrupted.
IOError is no longer raised due to a read system call returning EINTR from
within these methods.
2012-06-25 20:57:36 -07:00
Raymond Hettinger
aad5b02e62
Improve tooltips for splitlines() by showing that the default for keepends is False.
2012-06-02 01:42:58 -04:00
Martin v. Löwis
ed11a5d018
Issue #8767 : Restore building with --disable-unicode.
...
Original patch by Stefano Taschini.
2012-05-20 10:42:17 +02:00
Benjamin Peterson
f1ae5cf5c7
fix possible refleak ( closes #14752 )
2012-05-08 09:22:24 -04:00
Benjamin Peterson
d62da9d658
close() doesn't take any args ( closes #14717 )
2012-05-03 18:44:09 -04:00
Benjamin Peterson
f3ad1f94a8
use formats that work on 2.7
2012-05-01 10:16:33 -04:00
Benjamin Peterson
042c47b2c7
fix calling the classmethod descriptor directly ( closes #14699 )
2012-05-01 09:51:09 -04:00
Benjamin Peterson
d157a4c3dd
don't use a slot wrapper from a different special method ( closes #14658 )
...
This also alters the fix to #11603 . Specifically, setting __repr__ to
object.__str__ now raises a recursion RuntimeError when str() or repr() is
called instead of silently bypassing the recursion. I believe this behavior is
more correct.
2012-04-24 11:06:25 -04:00
Benjamin Peterson
76605557ea
SETUP_WITH acts like SETUP_FINALLY for the purposes of setting f_lineno ( closes #14612 )
2012-04-18 11:14:31 -04:00
Benjamin Peterson
fe146ea3c7
merge 2.7 release branch
2012-04-09 14:54:09 -04:00
Benjamin Peterson
f51c384a0a
fix build without Py_DEBUG and DNDEBUG ( closes #14509 )
2012-04-09 14:53:07 -04:00
Antoine Pitrou
02a380105d
Issue #14505 : Fix file descriptor leak when deallocating file objects created with PyFile_FromString().
2012-04-05 14:07:52 +02:00
Antoine Pitrou
fe9417726c
Issue #13019 : Fix potential reference leaks in bytearray.extend().
...
Patch by Suman Saha.
2012-04-01 16:05:46 +02:00
Benjamin Peterson
e8ecc73844
kill this terribly outdated comment
2012-03-25 22:40:54 -04:00
Benjamin Peterson
dbc52f8a0d
check for string attribute names in old-style classes ( closes #14334 )
2012-03-16 10:58:46 -05:00
Benjamin Peterson
6e7832b04c
check to make sure the attribute is a string ( #14334 )
2012-03-16 09:32:59 -05:00
Ezio Melotti
eace3a7261
#14161 : fix compile error under Windows.
2012-03-12 01:28:45 +02:00
Ezio Melotti
11f8b6872a
#14161 : fix the __repr__ of file objects to escape the file name.
2012-03-12 01:17:02 +02:00
Benjamin Peterson
9d7601fcea
merge 2.6
2012-02-21 11:24:21 -05:00
Benjamin Peterson
26da920001
ensure no one tries to hash things before the random seed is found
2012-02-21 11:08:50 -05:00
Benjamin Peterson
aee9dfba4a
merge 2.6 with hash randomization fix
2012-02-20 21:44:56 -05:00
Barry Warsaw
1e13eb084f
- Issue #13703 : oCERT-2011-003: add -R command-line option and PYTHONHASHSEED
...
environment variable, to provide an opt-in way to protect against denial of
service attacks due to hash collisions within the dict and set types. Patch
by David Malcolm, based on work by Victor Stinner.
2012-02-20 20:42:21 -05:00
Éric Araujo
a4c81b07f8
Fix typo
2012-02-20 02:07:31 +01:00
Benjamin Peterson
32c49d9533
use Py_CLEAR
2012-02-19 01:11:56 -05:00
Antoine Pitrou
fd7e4964bb
Fix indentation.
2012-02-15 02:57:19 +01:00
Antoine Pitrou
c66ed457ef
Issue #13020 : Fix a reference leak when allocating a structsequence object fails.
...
Patch by Suman Saha.
2012-02-15 02:51:43 +01:00
Benjamin Peterson
0f7e2df2f1
this is only a borrowed ref in Brett's branch
2012-02-10 08:46:54 -05:00
Benjamin Peterson
cec6a61d30
bltinmod is borrowed, so it shouldn't be decrefed
2012-02-06 11:28:45 -05:00
Benjamin Peterson
4c79aec716
put returns on their own lines
2012-02-03 19:22:31 -05:00
Mark Dickinson
1abe6cd842
Issue #13889 : Add missing _Py_SET_53BIT_PRECISION_* calls around uses of dtoa.c functions in float round.
2012-01-27 21:16:01 +00:00
Benjamin Peterson
a8d458560e
allow cycles throught the __dict__ slot to be cleared ( closes #1469629 )
...
Patch from Armin, test from me.
2012-03-07 18:41:11 -06:00
Antoine Pitrou
6a1cd1b3b1
Issue #13521 : dict.setdefault() now does only one lookup for the given key, making it "atomic" for many purposes.
...
Patch by Filip Gruszczyński.
2012-02-27 00:45:12 +01:00
Georg Brandl
6f14c330fa
Small clarification in docstring of dict.update(): the positional argument is not required.
2011-12-18 19:30:55 +01:00
Antoine Pitrou
5b4b2da55d
Fix the fix for issue #12149 : it was incorrect, although it had the side
...
effect of appearing to resolve the issue. Thanks to Mark Shannon for
noticing.
2011-12-15 14:15:31 +01:00
Victor Stinner
975134e2a2
Issue #13093 : Fix error handling on PyUnicode_EncodeDecimal()
...
Add tests for PyUnicode_EncodeDecimal()
2011-11-22 01:54:19 +01:00
Raymond Hettinger
7d1483cbad
Make an error message more understandable and consistent with other error messages.
2011-11-20 10:38:53 -08:00
Antoine Pitrou
30402549de
Issue #13333 : The UTF-7 decoder now accepts lone surrogates
...
(the encoder already accepts them).
2011-11-15 01:49:40 +01:00
Eli Bendersky
d784185303
Issue #13161 : fix doc strings of __i*__ operators
2011-11-11 16:52:16 +02:00
Petri Lehtinen
3b9d92aefe
Revert "Accept None as start and stop parameters for list.index() and tuple.index()"
...
Issue #13340 .
2011-11-06 20:59:01 +02:00
Petri Lehtinen
819d8d447d
Accept None as start and stop parameters for list.index() and tuple.index()
...
Closes #13340 .
2011-11-05 23:18:06 +02:00
Benjamin Peterson
e3b5eda8be
remove unused variable
2011-10-30 14:24:44 -04:00
Petri Lehtinen
a39de111a5
Fix the return value of set_discard (issue #10519 )
2011-10-30 14:33:09 +02:00
Petri Lehtinen
5f4d870668
Avoid unnecessary recursive function calls ( closes #10519 )
2011-10-30 13:55:56 +02:00
Petri Lehtinen
8ffbab8d02
Issue #13018 : Fix reference leaks in error paths in dictobject.c.
...
Patch by Suman Saha.
2011-10-24 20:59:29 +03:00
Benjamin Peterson
a7b0976c3e
PyEval_CallObject requires a tuple of args ( closes #13186 )
2011-10-15 13:43:21 -04:00
Nadeem Vawda
36248154a9
Issue #13159 : Replace FileIO's quadratic-time buffer growth algorithm with a linear-time one.
...
Also fix the builtin file class and the bz2 module, which used the same algorithm.
2011-10-13 13:52:46 +02:00
Victor Stinner
63c22fac72
Issue #7732 : Fix a crash on importing a module if a directory has the same name
...
than a Python module (e.g. "__init__.py"): don't close the file twice.
PyFile_FromFile() does also close the file if PyString_FromString() failed. It
did already close the file on fill_file_fields() error (e.g. if the file is a
directory).
2011-09-23 19:37:03 +02:00
Mark Dickinson
4ac5d2cda4
Backport issue #12973 list_repeat fix from 3.x.
2011-09-19 19:23:55 +01:00
Mark Dickinson
dbbed04941
Issue #12973 : Fix int.__pow__ overflow checks that invoked undefined behaviour, thereby producing incorrect results on Clang.
2011-09-19 16:38:08 +01:00
Benjamin Peterson
de66ecc75f
fix possible refleaks
2011-08-16 22:26:48 -05:00
Ezio Melotti
15d6b65ead
#12266 : Fix str.capitalize() to correctly uppercase/lowercase titlecased and cased non-letter characters.
2011-08-15 09:22:24 +03:00
Senthil Kumaran
5e3a19d806
merge from 3.2 - Fix closes Issue12621 - Fix docstrings of find and rfind methods of bytes/bytearry/unicodeobject.
2011-07-27 23:36:51 +08:00
Antoine Pitrou
304f0f952d
Issue #11603 : Fix a crash when __str__ is rebound as __repr__.
...
Patch by Andreas Stührk.
2011-07-15 21:22:50 +02:00
Antoine Pitrou
1616645a00
Issue #12149 : Update the method cache after a type's dictionnary gets
...
cleared by the garbage collector. This fixes a segfault when an instance
and its type get caught in a reference cycle, and the instance's
deallocator calls one of the methods on the type (e.g. when subclassing
IOBase).
Diagnosis and patch by Davide Rizzo.
2011-07-12 22:04:20 +02:00
Raymond Hettinger
bf7a266074
Fixup repr for dict_proxy objects.
2011-06-30 00:44:36 +01:00
Mark Dickinson
cb9bf1ac9c
Issue #12164 : Document (in docstring) that str.translate accepts None for the first argument.
2011-06-25 11:00:12 +02:00
Benjamin Peterson
80a09c70bf
use '->' to indicate return values
2011-05-24 12:42:51 -05:00
Benjamin Peterson
7f5cd45f1d
must clear an AttributeError if it is set
2011-05-23 18:17:55 -05:00
Benjamin Peterson
fd89af59e8
handle old-style instances
2011-05-23 17:11:21 -05:00
Benjamin Peterson
8de87a6403
correctly lookup __dir__
2011-05-23 16:11:05 -05:00
Victor Stinner
e363ec1057
(Merge 3.1) Issue #9756 : When calling a method descriptor or a slot wrapper
...
descriptor, the check of the object type doesn't read the __class__ attribute
anymore. Fix a crash if a class override its __class__ attribute (e.g. a proxy
of the str type).
2011-05-01 23:43:37 +02:00
Ezio Melotti
e3685f6b1b
#6780 : fix starts/endswith error message to mention that tuples are accepted too.
2011-04-26 05:12:51 +03:00
Jesus Cea
44e81687a2
startswith and endswith don't accept None as slice index. Patch by Torsten Becker. ( closes #11828 )
2011-04-20 16:39:15 +02:00
Mark Dickinson
874d59ee91
Issue #11144 : Fix corner cases where float-to-int conversion unnecessarily returned a long.
2011-03-26 12:18:00 +00:00
Eli Bendersky
72de205895
Issue #11634 : Remove misleading paragraph from a comment
2011-03-24 22:38:25 +02:00
Éric Araujo
f079c9bfbf
Fix obscure set crashers ( #4420 ). Backport of d56b3cafb1e6, reviewed by Raymond.
2011-03-22 23:47:32 +01:00
Ezio Melotti
c2077b0d9b
#11565 : Fix several typos. Patch by Piotr Kasprzyk.
2011-03-16 12:34:31 +02:00
Ezio Melotti
24b07bcba3
#11515 : fix several typos. Patch by Piotr Kasprzyk.
2011-03-15 18:55:01 +02:00
Eli Bendersky
680e6eb54f
Merged revisions 88735 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r88735 | eli.bendersky | 2011-03-04 06:55:25 +0200 (Fri, 04 Mar 2011) | 2 lines
Issue #11386 : Fixed the exception thrown by bytearray.pop() for empty bytearrays
........
2011-03-04 06:14:56 +00:00
Georg Brandl
28dadd988b
Merged revisions 87050,87101,87146,87156,87172,87175,87371,87378,87522-87524,87526,87530-87535 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r87050 | georg.brandl | 2010-12-04 18:09:30 +0100 (Sa, 04 Dez 2010) | 1 line
Fix typo.
........
r87101 | georg.brandl | 2010-12-06 23:02:48 +0100 (Mo, 06 Dez 2010) | 1 line
Remove visible XXX comments.
........
r87146 | georg.brandl | 2010-12-09 19:08:43 +0100 (Do, 09 Dez 2010) | 1 line
Fix "seperate".
........
r87156 | georg.brandl | 2010-12-10 11:01:44 +0100 (Fr, 10 Dez 2010) | 1 line
#10668 : fix wrong call of __init__.
........
r87172 | georg.brandl | 2010-12-11 20:10:30 +0100 (Sa, 11 Dez 2010) | 1 line
Avoid AttributeError(_closed) when a TemporaryDirectory is deallocated whose mkdtemp call failed.
........
r87175 | georg.brandl | 2010-12-11 23:19:34 +0100 (Sa, 11 Dez 2010) | 1 line
Fix markup.
........
r87371 | georg.brandl | 2010-12-18 17:21:58 +0100 (Sa, 18 Dez 2010) | 1 line
Fix typo.
........
r87378 | georg.brandl | 2010-12-18 18:51:28 +0100 (Sa, 18 Dez 2010) | 1 line
#10723 : add missing builtin exceptions.
........
r87522 | georg.brandl | 2010-12-28 10:16:12 +0100 (Di, 28 Dez 2010) | 1 line
Replace sys.maxint mention by sys.maxsize.
........
r87523 | georg.brandl | 2010-12-28 10:18:24 +0100 (Di, 28 Dez 2010) | 1 line
Remove confusing paragraph -- this is relevant only to advanced users anyway and does not belong into the tutorial.
........
r87524 | georg.brandl | 2010-12-28 10:29:19 +0100 (Di, 28 Dez 2010) | 1 line
Fix advice: call PyType_Ready to fill in ob_type of custom types.
........
r87526 | georg.brandl | 2010-12-28 11:38:33 +0100 (Di, 28 Dez 2010) | 1 line
#10777 : fix iteration over dict keys while mutating the dict.
........
r87530 | georg.brandl | 2010-12-28 12:06:07 +0100 (Di, 28 Dez 2010) | 1 line
#10767 : update README in crashers; not all may have a bug entry and/or be fixed.
........
r87531 | georg.brandl | 2010-12-28 12:08:17 +0100 (Di, 28 Dez 2010) | 1 line
#10742 : document readonly attribute of memoryviews.
........
r87532 | georg.brandl | 2010-12-28 12:15:49 +0100 (Di, 28 Dez 2010) | 1 line
#10781 : clarify that *encoding* is not a parameter for Node objects in general.
........
r87533 | georg.brandl | 2010-12-28 12:38:12 +0100 (Di, 28 Dez 2010) | 1 line
Remove history; adapt a bit more to reST, since this will once be part of the dev guide.
........
r87534 | georg.brandl | 2010-12-28 12:48:53 +0100 (Di, 28 Dez 2010) | 1 line
Rewrap.
........
r87535 | georg.brandl | 2010-12-28 12:49:41 +0100 (Di, 28 Dez 2010) | 1 line
#10739 : document that on Windows, socket.makefile() does not make a file that has a true file descriptor usable where such a thing is expected.
........
2011-02-25 10:50:32 +00:00
Antoine Pitrou
3013b16b62
Merged revisions 88097 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r88097 | antoine.pitrou | 2011-01-18 19:57:52 +0100 (mar., 18 janv. 2011) | 4 lines
Issue #10451 : memoryview objects could allow to mutate a readable buffer.
Initial patch by Ross Lagerwall.
........
2011-01-18 19:06:19 +00:00
Benjamin Peterson
fba33478a5
Merged revisions 88069 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r88069 | benjamin.peterson | 2011-01-17 13:54:55 -0600 (Mon, 17 Jan 2011) | 1 line
remove unneeded assertion
........
2011-01-17 19:57:01 +00:00
Benjamin Peterson
cd8500193f
Merged revisions 88066 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r88066 | benjamin.peterson | 2011-01-17 13:44:46 -0600 (Mon, 17 Jan 2011) | 1 line
correct assertion
........
2011-01-17 19:48:58 +00:00
Benjamin Peterson
cf94b8b4da
Merged revisions 88063 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r88063 | benjamin.peterson | 2011-01-17 13:24:34 -0600 (Mon, 17 Jan 2011) | 4 lines
turn some checks into assertions, since they are implied by the caller
Reviewed by Georg.
........
2011-01-17 19:30:29 +00:00
Benjamin Peterson
f4676b0378
Merged revisions 87960 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r87960 | benjamin.peterson | 2011-01-12 12:56:07 -0600 (Wed, 12 Jan 2011) | 1 line
use PyErr_SetString instead of PyErr_Format
........
2011-01-12 19:00:37 +00:00
Benjamin Peterson
9b911ca14d
Merged revisions 87952-87954 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r87952 | benjamin.peterson | 2011-01-12 09:24:27 -0600 (Wed, 12 Jan 2011) | 1 line
move this test to test_descr; it's not abc specific
........
r87953 | benjamin.peterson | 2011-01-12 09:25:02 -0600 (Wed, 12 Jan 2011) | 1 line
oops, wrong class
........
r87954 | benjamin.peterson | 2011-01-12 09:34:01 -0600 (Wed, 12 Jan 2011) | 1 line
don't segfault on deleting __abstractmethods__ #10892
........
2011-01-12 15:49:47 +00:00
Antoine Pitrou
5a72e76b69
Merged revisions 87834 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r87834 | antoine.pitrou | 2011-01-07 22:43:59 +0100 (ven., 07 janv. 2011) | 5 lines
Issue #8020 : Avoid a crash where the small objects allocator would read
non-Python managed memory while it is being modified by another thread.
Patch by Matt Bandy.
........
2011-01-07 21:49:44 +00:00
Mark Dickinson
ecf8ec67ce
Merged revisions 87032 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r87032 | mark.dickinson | 2010-12-04 12:25:30 +0000 (Sat, 04 Dec 2010) | 3 lines
Issue #10596 : Fix float.__mod__ to have the same behaviour as
float.__divmod__ with respect to signed zeros.
........
2010-12-04 12:30:41 +00:00
Stefan Krah
918c90ce06
Merged revisions 86791 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r86791 | stefan.krah | 2010-11-26 11:54:09 +0100 (Fri, 26 Nov 2010) | 1 line
Indentation cleanup.
........
2010-11-26 11:03:55 +00:00
Armin Rigo
39e32a7e81
Revert r86726. Sorry about interfering with the rc.
2010-11-24 13:17:48 +00:00
Armin Rigo
442e4477fe
A no-op change. It looks like this call was not meant to be a recursive
...
call, but just call the helper (which the recursive call ends up doing).
2010-11-24 10:39:23 +00:00
Eric Smith
6c84085cfb
Improved docstrings for str and unicode methods format and __format__.
2010-11-06 19:43:44 +00:00
Jesus Cea
33c722b795
CObject use is marked as a Py3k warning, not a deprecation warning
2010-11-04 21:39:52 +00:00
Raymond Hettinger
2ad17e19ee
Issue 10221: Improve error message for dict.pop().
2010-10-30 08:17:46 +00:00
Antoine Pitrou
638cee62d5
Issue #9295 : Fix a crash under Windows when calling close() on a file
...
object with custom buffering from two threads at once.
2010-10-28 14:50:57 +00:00
Benjamin Peterson
bf775542b0
iterators passed to writelines() can close their files; don't segfault #10125
2010-10-16 19:20:12 +00:00
Benjamin Peterson
dc9542435b
Merged revisions 85392 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r85392 | benjamin.peterson | 2010-10-12 17:57:59 -0500 (Tue, 12 Oct 2010) | 1 line
prefer clearing global objects to obscure module.__dict__ bugs #10068
........
2010-10-12 23:02:35 +00:00
Benjamin Peterson
35c6be0b74
Merged revisions 85193 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r85193 | benjamin.peterson | 2010-10-02 21:13:39 -0500 (Sat, 02 Oct 2010) | 1 line
typo
........
2010-10-03 02:17:04 +00:00
Benjamin Peterson
a5d5cc45c9
Merged revisions 85154 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r85154 | benjamin.peterson | 2010-10-01 19:03:31 -0500 (Fri, 01 Oct 2010) | 1 line
type.__abstractmethods__ should raise an AttributeError #10006
........
2010-10-02 00:08:58 +00:00
Mark Dickinson
cb61e5d9b5
Issue #9869 : Make long() and PyNumber_Long return something of type
...
long for a class whose __long__ method returns a plain int. This
fixes an interpreter crash (due to long_subtype_new assuming
PyNumber_Long returns a long) when initializing an instance of a long
subclass from an object whose __long__ method returns a plain int.
2010-09-26 10:37:12 +00:00
Victor Stinner
caafd77060
Issue #4947 : The write() method of sys.stdout and sys.stderr uses their
...
encoding and errors attributes instead of using utf-8 in strict mode, to get
the same behaviour than the print statement.
2010-09-08 10:51:01 +00:00
Antoine Pitrou
9cf85f144e
Merged revisions 84408-84409 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r84408 | antoine.pitrou | 2010-09-01 23:14:16 +0200 (mer., 01 sept. 2010) | 4 lines
Issue #9737 : Fix a crash when trying to delete a slice or an item from
a memoryview object.
........
r84409 | antoine.pitrou | 2010-09-01 23:14:46 +0200 (mer., 01 sept. 2010) | 3 lines
Fix a compilation warning
........
2010-09-01 21:17:34 +00:00
Antoine Pitrou
1fcdba84be
Merged revisions 84391 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r84391 | antoine.pitrou | 2010-09-01 14:58:21 +0200 (mer., 01 sept. 2010) | 5 lines
Issue #3101 : Helper functions _add_one_to_C() and _add_one_to_F() become
_Py_add_one_to_C() and _Py_add_one_to_F(), respectively.
........
2010-09-01 13:02:50 +00:00
Antoine Pitrou
a408350a08
Merged revisions 84344 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r84344 | antoine.pitrou | 2010-08-28 20:17:03 +0200 (sam., 28 août 2010) | 4 lines
Issue #1868 : Eliminate subtle timing issues in thread-local objects by
getting rid of the cached copy of thread-local attribute dictionary.
........
2010-08-28 18:29:13 +00:00
Benjamin Peterson
6f3d6a9b23
Merged revisions 84320 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r84320 | benjamin.peterson | 2010-08-25 18:13:17 -0500 (Wed, 25 Aug 2010) | 1 line
basicsize and itemsize are Py_ssize_t #9688
........
2010-08-25 23:17:42 +00:00
Alexander Belopolsky
b8de9fab30
Merged revisions 84106 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r84106 | alexander.belopolsky | 2010-08-16 16:17:07 -0400 (Mon, 16 Aug 2010) | 1 line
Issue #8983 : Corrected docstrings.
........
2010-08-16 20:30:26 +00:00
Florent Xicluna
172e15fdd6
Merged revisions 83833,83838-83839,83859,83878 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r83833 | florent.xicluna | 2010-08-08 18:25:27 +0200 (dim., 08 août 2010) | 2 lines
Add test case for the HTTPResponse being an iterable. Follow-up of issue #4608 .
........
r83838 | florent.xicluna | 2010-08-08 20:03:44 +0200 (dim., 08 août 2010) | 2 lines
Typo.
........
r83839 | florent.xicluna | 2010-08-08 20:06:13 +0200 (dim., 08 août 2010) | 2 lines
Issue #7564 : Skip test_ioctl if another process is attached to /dev/tty.
........
r83859 | florent.xicluna | 2010-08-09 00:07:16 +0200 (lun., 09 août 2010) | 2 lines
Fix #8530 : Prevent stringlib fastsearch from reading beyond the front of an array.
........
r83878 | florent.xicluna | 2010-08-09 10:29:08 +0200 (lun., 09 août 2010) | 1 line
Merge the 2to3 script from /sandbox/trunk/2to3/2to3, revision 72867 (latest).
........
2010-08-09 20:02:00 +00:00
Raymond Hettinger
3ad323ecaf
Issue8757: Implicit set-to-frozenset conversion not thread-safe.
2010-08-06 10:18:56 +00:00
Georg Brandl
c5356994ed
Merged revisions 83354,83365 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/release27-maint
........
r83354 | georg.brandl | 2010-07-31 21:07:37 +0200 (Sa, 31 Jul 2010) | 1 line
#9328 : string format methods return strings.
........
r83365 | georg.brandl | 2010-07-31 23:22:36 +0200 (Sa, 31 Jul 2010) | 1 line
#1019882 : if start() and stop() were not in the same stack frame, stats.load() would crash with IndexError.
........
2010-08-01 22:02:09 +00:00
Georg Brandl
6290bcfc25
Merged revisions 83452,83457,83466,83471,83475,83480,83486 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/release27-maint
................
r83452 | georg.brandl | 2010-08-01 23:06:46 +0200 (So, 01 Aug 2010) | 25 lines
Merged revisions 83226-83227,83229-83230,83232 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r83226 | georg.brandl | 2010-07-29 16:17:12 +0200 (Do, 29 Jul 2010) | 1 line
#1090076 : explain the behavior of *vars* in get() better.
........
r83227 | georg.brandl | 2010-07-29 16:23:06 +0200 (Do, 29 Jul 2010) | 1 line
Use Py_CLEAR().
........
r83229 | georg.brandl | 2010-07-29 16:32:22 +0200 (Do, 29 Jul 2010) | 1 line
#9407 : document configparser.Error.
........
r83230 | georg.brandl | 2010-07-29 16:36:11 +0200 (Do, 29 Jul 2010) | 1 line
Use correct directive and name.
........
r83232 | georg.brandl | 2010-07-29 16:49:08 +0200 (Do, 29 Jul 2010) | 1 line
#9388 : remove ERA_YEAR which is never defined in the source code.
........
................
r83457 | georg.brandl | 2010-08-01 23:10:57 +0200 (So, 01 Aug 2010) | 9 lines
Merged revisions 83223 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r83223 | georg.brandl | 2010-07-29 15:38:37 +0200 (Do, 29 Jul 2010) | 1 line
#3874 : document HTMLParser.unknown_decl().
........
................
r83466 | georg.brandl | 2010-08-01 23:23:50 +0200 (So, 01 Aug 2010) | 29 lines
Merged revisions 83160-83161,83166,83168-83169,83171 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r83160 | georg.brandl | 2010-07-26 10:51:42 +0200 (Mo, 26 Jul 2010) | 1 line
#9381 : fix markup.
........
r83161 | georg.brandl | 2010-07-26 11:33:12 +0200 (Mo, 26 Jul 2010) | 1 line
Add Brian Quinlan.
........
r83166 | georg.brandl | 2010-07-26 17:11:49 +0200 (Mo, 26 Jul 2010) | 1 line
Fix grammar.
........
r83168 | georg.brandl | 2010-07-26 19:00:20 +0200 (Mo, 26 Jul 2010) | 1 line
Fix indentation in example.
........
r83169 | georg.brandl | 2010-07-26 19:09:32 +0200 (Mo, 26 Jul 2010) | 1 line
Add Reid.
........
r83171 | georg.brandl | 2010-07-26 23:12:13 +0200 (Mo, 26 Jul 2010) | 1 line
Clarify.
........
................
r83471 | georg.brandl | 2010-08-01 23:26:45 +0200 (So, 01 Aug 2010) | 9 lines
Merged revisions 83106 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r83106 | georg.brandl | 2010-07-23 18:55:26 +0200 (Fr, 23 Jul 2010) | 1 line
Fix some markup glitches.
........
................
r83475 | georg.brandl | 2010-08-01 23:28:47 +0200 (So, 01 Aug 2010) | 9 lines
Merged revisions 82965 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r82965 | georg.brandl | 2010-07-19 13:28:05 +0200 (Mo, 19 Jul 2010) | 1 line
Clarification. Yay importlib!
........
................
r83480 | georg.brandl | 2010-08-01 23:33:42 +0200 (So, 01 Aug 2010) | 17 lines
Merged revisions 82871,82960-82961 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r82871 | georg.brandl | 2010-07-14 10:00:22 +0200 (Mi, 14 Jul 2010) | 1 line
#9258 : fix copy-paste errors.
........
r82960 | georg.brandl | 2010-07-19 08:52:35 +0200 (Mo, 19 Jul 2010) | 1 line
Clarify.
........
r82961 | georg.brandl | 2010-07-19 08:57:52 +0200 (Mo, 19 Jul 2010) | 1 line
Clarify :option: description.
........
................
r83486 | georg.brandl | 2010-08-01 23:44:38 +0200 (So, 01 Aug 2010) | 13 lines
Merged revisions 82832,82834 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r82832 | georg.brandl | 2010-07-12 11:00:29 +0200 (Mo, 12 Jul 2010) | 1 line
Take care of duplicate target name warnings.
........
r82834 | georg.brandl | 2010-07-12 11:06:13 +0200 (Mo, 12 Jul 2010) | 1 line
Use raw string literals for regexes containing backlash.
........
................
2010-08-01 21:48:47 +00:00
Georg Brandl
d070cc5350
Merged revisions 83226-83227,83229-83230,83232 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r83226 | georg.brandl | 2010-07-29 16:17:12 +0200 (Do, 29 Jul 2010) | 1 line
#1090076 : explain the behavior of *vars* in get() better.
........
r83227 | georg.brandl | 2010-07-29 16:23:06 +0200 (Do, 29 Jul 2010) | 1 line
Use Py_CLEAR().
........
r83229 | georg.brandl | 2010-07-29 16:32:22 +0200 (Do, 29 Jul 2010) | 1 line
#9407 : document configparser.Error.
........
r83230 | georg.brandl | 2010-07-29 16:36:11 +0200 (Do, 29 Jul 2010) | 1 line
Use correct directive and name.
........
r83232 | georg.brandl | 2010-07-29 16:49:08 +0200 (Do, 29 Jul 2010) | 1 line
#9388 : remove ERA_YEAR which is never defined in the source code.
........
2010-08-01 21:06:46 +00:00
Georg Brandl
e27d044769
Recorded merge of revisions 83444 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r83444 | georg.brandl | 2010-08-01 22:51:02 +0200 (So, 01 Aug 2010) | 1 line
Revert r83395, it introduces test failures and is not necessary anyway since we now have to nul-terminate the string anyway.
........
2010-08-01 20:54:30 +00:00
Georg Brandl
09f0d60f7c
Merged revisions 83395 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r83395 | georg.brandl | 2010-08-01 10:49:18 +0200 (So, 01 Aug 2010) | 1 line
#8821 : do not rely on Unicode strings being terminated with a \u0000, rather explicitly check range before looking for a second surrogate character.
........
2010-08-01 18:41:59 +00:00
Mark Dickinson
aad57bd1bb
Merged revisions 83400 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r83400 | mark.dickinson | 2010-08-01 11:41:49 +0100 (Sun, 01 Aug 2010) | 7 lines
Issue #9416 : Fix some issues with complex formatting where the
output with no type specifier failed to match the str output:
- format(complex(-0.0, 2.0), '-') omitted the real part from the output,
- format(complex(0.0, 2.0), '-') included a sign and parentheses.
........
2010-08-01 10:45:15 +00:00
Georg Brandl
05f819b6e9
#9328 : string format methods return strings.
2010-07-31 19:07:37 +00:00
Stefan Krah
ae7dd8fab0
Merged revisions 82980 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/release27-maint
........
r82980 | stefan.krah | 2010-07-19 20:06:46 +0200 (Mon, 19 Jul 2010) | 3 lines
Sub-issue of #9036 : Fix incorrect use of Py_CHARMASK.
........
2010-07-19 18:24:18 +00:00
Stefan Krah
0b9201fa1c
Sub-issue of #9036 : Fix incorrect use of Py_CHARMASK.
2010-07-19 18:06:46 +00:00
Antoine Pitrou
3266978300
Merged revisions 82814 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r82814 | antoine.pitrou | 2010-07-11 14:12:00 +0200 (dim., 11 juil. 2010) | 4 lines
Issue #7616 : Fix copying of overlapping memoryview slices with the Intel
compiler.
........
2010-07-11 12:14:05 +00:00
Senthil Kumaran
5261b10556
Merged revisions 82573 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r82573 | senthil.kumaran | 2010-07-05 17:30:56 +0530 (Mon, 05 Jul 2010) | 3 lines
Fix the docstrings of the capitalize method.
........
2010-07-05 12:04:07 +00:00
Ezio Melotti
86e5e17bda
Merged revisions 81758-81759 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r81758 | ezio.melotti | 2010-06-05 20:51:07 +0300 (Sat, 05 Jun 2010) | 15 lines
Update PyUnicode_DecodeUTF8 from RFC 2279 to RFC 3629.
1) #8271 : when a byte sequence is invalid, only the start byte and all the
valid continuation bytes are now replaced by U+FFFD, instead of replacing
the number of bytes specified by the start byte.
See http://www.unicode.org/versions/Unicode5.2.0/ch03.pdf (pages 94-95);
2) 5- and 6-bytes-long UTF-8 sequences are now considered invalid (no changes
in behavior);
3) Add code and tests to reject surrogates (U+D800-U+DFFF) as defined in
RFC 3629, but leave it commented out since it's not backward compatible;
4) Change the error messages "unexpected code byte" to "invalid start byte"
and "invalid data" to "invalid continuation byte";
5) Add an extensive set of tests in test_unicode;
6) Fix test_codeccallbacks because it was failing after this change.
........
r81759 | ezio.melotti | 2010-06-05 22:21:32 +0300 (Sat, 05 Jun 2010) | 1 line
Add a NEWS entry for r81758 and clarify a comment.
........
2010-07-03 05:34:39 +00:00
Benjamin Peterson
df1bc015f2
Merged revisions 82447 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r82447 | benjamin.peterson | 2010-07-02 14:41:39 -0500 (Fri, 02 Jul 2010) | 1 line
add space
........
2010-07-02 19:45:11 +00:00
Benjamin Peterson
cf76d1f0c7
add space
2010-07-02 19:41:39 +00:00
Benjamin Peterson
4c5bc4d7f8
remove unused last argument to property_copy
2010-06-28 02:58:25 +00:00
Ezio Melotti
6327bf1c6a
Merged revisions 82248 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r82248 | ezio.melotti | 2010-06-26 21:44:42 +0300 (Sat, 26 Jun 2010) | 1 line
Fix extra space.
........
2010-06-26 18:47:01 +00:00
Ezio Melotti
2f06b78d61
Fix extra space.
2010-06-26 18:44:42 +00:00
Benjamin Peterson
8d6496385d
Merged revisions 82157 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r82157 | benjamin.peterson | 2010-06-22 14:16:37 -0500 (Tue, 22 Jun 2010) | 1 line
remove INT_MAX assertions; they can fail with large Py_ssize_t #9058
........
2010-06-22 19:21:33 +00:00
Benjamin Peterson
b91338960e
remove INT_MAX assertions; they can fail with large Py_ssize_t #9058
2010-06-22 19:16:37 +00:00
Benjamin Peterson
8e5effaaa4
fix warning with ucs4
2010-06-12 17:47:06 +00:00
Antoine Pitrou
4595e51817
Merged revisions 81907 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r81907 | antoine.pitrou | 2010-06-11 23:42:26 +0200 (ven., 11 juin 2010) | 5 lines
Issue #8941 : decoding big endian UTF-32 data in UCS-2 builds could crash
the interpreter with characters outside the Basic Multilingual Plane
(higher than 0x10000).
........
2010-06-11 21:48:02 +00:00
Antoine Pitrou
cca3a3f396
Issue #8941 : decoding big endian UTF-32 data in UCS-2 builds could crash
...
the interpreter with characters outside the Basic Multilingual Plane
(higher than 0x10000).
2010-06-11 21:42:26 +00:00
Antoine Pitrou
96ec48b414
Merged revisions 81860 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r81860 | antoine.pitrou | 2010-06-09 18:24:00 +0200 (mer., 09 juin 2010) | 3 lines
Issue #8930 : fix some C code indentation
........
2010-06-09 16:31:23 +00:00
Antoine Pitrou
619f16e194
Issue #8930 : fix some C code indentation
2010-06-09 16:24:00 +00:00
Benjamin Peterson
7dbe3e31c1
remove extra byte and fix comment
2010-06-07 22:32:44 +00:00
Benjamin Peterson
c971913f84
Merged revisions 81820 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r81820 | benjamin.peterson | 2010-06-07 17:23:23 -0500 (Mon, 07 Jun 2010) | 1 line
correctly overflow when indexes are too large
........
2010-06-07 22:27:32 +00:00
Benjamin Peterson
13e934acc0
correctly overflow when indexes are too large
2010-06-07 22:23:23 +00:00
Benjamin Peterson
c4afe2950a
locale grouping strings should end in '\0'
2010-06-07 21:37:09 +00:00
Ezio Melotti
e57e50c8e7
Update PyUnicode_DecodeUTF8 from RFC 2279 to RFC 3629.
...
1) #8271 : when a byte sequence is invalid, only the start byte and all the
valid continuation bytes are now replaced by U+FFFD, instead of replacing
the number of bytes specified by the start byte.
See http://www.unicode.org/versions/Unicode5.2.0/ch03.pdf (pages 94-95);
2) 5- and 6-bytes-long UTF-8 sequences are now considered invalid (no changes
in behavior);
3) Add code and tests to reject surrogates (U+D800-U+DFFF) as defined in
RFC 3629, but leave it commented out since it's not backward compatible;
4) Change the error messages "unexpected code byte" to "invalid start byte"
and "invalid data" to "invalid continuation byte";
5) Add an extensive set of tests in test_unicode;
6) Fix test_codeccallbacks because it was failing after this change.
2010-06-05 17:51:07 +00:00
Mark Dickinson
3bf9f1a4e9
Merged revisions 81744 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r81744 | mark.dickinson | 2010-06-05 13:51:21 +0100 (Sat, 05 Jun 2010) | 1 line
Fix comment typo.
........
2010-06-05 12:52:03 +00:00
Mark Dickinson
77acee9567
Fix comment typo.
2010-06-05 12:51:21 +00:00
Mark Dickinson
b671c29336
Merged revisions 81740 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r81740 | mark.dickinson | 2010-06-05 13:14:43 +0100 (Sat, 05 Jun 2010) | 5 lines
Issue #8627 : Fix "XXX undetected error" from unchecked PyErr_WarnPy3k return.
This is just a quick fix: if the warning is turned into an exception, the
exception simply gets ignored.
........
2010-06-05 12:15:35 +00:00
Mark Dickinson
e4b83e013b
Issue #8627 : Fix "XXX undetected error" from unchecked PyErr_WarnPy3k return.
...
This is just a quick fix: if the warning is turned into an exception, the
exception simply gets ignored.
2010-06-05 12:14:43 +00:00
Mark Dickinson
80068da395
Merged revisions 81736 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r81736 | mark.dickinson | 2010-06-05 12:52:24 +0100 (Sat, 05 Jun 2010) | 1 line
Issue #8627 : remove out-of-date warning about overriding __cmp__
........
2010-06-05 11:59:41 +00:00
Mark Dickinson
23f0d6b57b
Issue #8627 : remove out-of-date warning about overriding __cmp__
2010-06-05 11:52:24 +00:00
Benjamin Peterson
d5adb5d73d
_PyObject_LookupSpecial returns a new reference
2010-06-05 02:07:01 +00:00
Benjamin Peterson
67783b1f71
fix ref counting
2010-06-05 01:00:10 +00:00
Benjamin Peterson
039c585805
implement object.__format__ with PyObject_Format
2010-06-05 00:56:46 +00:00
Benjamin Peterson
3a2acb5040
remove PyType_Ready call; float should be initialized in interpreter startup
2010-06-05 00:38:22 +00:00
Benjamin Peterson
2aa6c38237
properly lookup the __format__ special method
2010-06-05 00:32:50 +00:00
Mark Dickinson
4ca7c3c089
Issue #8748 : Fix incorrect results from comparisons between an integer
...
and a complex instance. Based on a patch by Meador Inge.
2010-05-30 13:18:10 +00:00
Mark Dickinson
4b3035d0b8
Remove declaration for unused variable.
2010-05-30 12:17:11 +00:00
Mark Dickinson
813363743d
Issue #5211 : Complete removal of implicit coercions for the complex
...
type. Coercion for arithmetic operations was already removed in
r78280, but that commit didn't remove coercion for rich comparisons.
2010-05-30 12:12:25 +00:00
Georg Brandl
e37049ccd7
Merged revisions 81468 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r81468 | georg.brandl | 2010-05-22 13:43:25 +0200 (Sa, 22 Mai 2010) | 1 line
#8635 : document enumerate() start parameter in docstring.
........
2010-05-22 11:44:30 +00:00
Georg Brandl
54d2898ef8
#8635 : document enumerate() start parameter in docstring.
2010-05-22 11:43:25 +00:00
Georg Brandl
2eeea685a8
Merged revisions 68750,68811,68945,69157 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r68750 | benjamin.peterson | 2009-01-18 22:47:04 +0000 (So, 18 Jan 2009) | 1 line
fix encoding cookie case
........
r68811 | benjamin.peterson | 2009-01-20 18:58:27 +0000 (Di, 20 Jan 2009) | 1 line
fix url
........
r68945 | tarek.ziade | 2009-01-25 22:11:04 +0000 (So, 25 Jan 2009) | 1 line
added missing module docstring
........
r69157 | benjamin.peterson | 2009-01-31 23:43:25 +0000 (Sa, 31 Jan 2009) | 1 line
add explanatory comment
........
2010-05-18 23:37:50 +00:00
Antoine Pitrou
5de1594e28
Merged revisions 81275 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r81275 | antoine.pitrou | 2010-05-17 21:56:59 +0200 (lun., 17 mai 2010) | 4 lines
Issue #7079 : Fix a possible crash when closing a file object while using
it from another thread. Patch by Daniel Stutzbach.
........
2010-05-17 20:00:52 +00:00
Antoine Pitrou
83137c2e16
Issue #7079 : Fix a possible crash when closing a file object while using
...
it from another thread. Patch by Daniel Stutzbach.
2010-05-17 19:56:59 +00:00
Mark Dickinson
43ca377e45
Wrap multiline macros in a 'do {} while(0)', for safety.
2010-05-09 20:42:09 +00:00
Mark Dickinson
fda8d114ea
Post-detabification cleanup: whitespace fixes and long line rewraps only.
2010-05-09 20:30:29 +00:00
Antoine Pitrou
c7c96a90bc
Recorded merge of revisions 81029 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r81029 | antoine.pitrou | 2010-05-09 16:46:46 +0200 (dim., 09 mai 2010) | 3 lines
Untabify C files. Will watch buildbots.
........
2010-05-09 15:15:40 +00:00
Antoine Pitrou
c83ea137d7
Untabify C files. Will watch buildbots.
2010-05-09 14:46:46 +00:00
Mark Dickinson
22ff664ff7
Issue #8659 : Remove redundant ABS calls. Thanks Daniel Stutzbach.
2010-05-08 08:01:19 +00:00
Brett Cannon
a8ac944924
Add back in a line that was unneeded which advanced a pointer, but commented
...
out as it is currently unneeded.
This effectively adds back in the line removed in r80809 as a comment.
2010-05-06 17:56:36 +00:00
Brett Cannon
8a478ced55
Remove an unneeded assignment.
...
Found using Clang's static analyzer.
2010-05-05 20:19:26 +00:00
Brett Cannon
fee3acb082
Remove an unneeded variable assignment.
...
Found using Clang's static analyzer.
2010-05-05 20:18:23 +00:00
Brett Cannon
eb3fef59b9
Remove an unneeded variable.
...
Found using Clang's static analyzer.
2010-05-05 20:16:50 +00:00
Brett Cannon
6f38175cbc
Remove an unneeded variable increment.
...
Found using Clang's static analyzer.
2010-05-05 20:16:09 +00:00
Alexandre Vassalotti
268e4872d3
Issue #8404 : Fix set operations on dictionary views.
2010-05-04 03:21:51 +00:00
Brett Cannon
0d8a859a85
Pull a NULL pointer check up to cover more cases in the function.
...
Found using Clang's static analyzer.
2010-05-04 01:23:36 +00:00
Brett Cannon
a7f13ee3f5
Remove an unneeded variable and assignment.
...
Found using Clang's static analyzer.
2010-05-04 01:16:51 +00:00
Mark Dickinson
328284adcf
Improve error message from nb_int returning a non-integer, in various PyInt_As* functions:
2010-05-02 09:38:43 +00:00
Raymond Hettinger
efa19849ce
Issue 8436: set.__init__ accepts keyword args
2010-04-18 22:59:34 +00:00
Raymond Hettinger
35b76027f9
Issue 8436: set.__init__ accepts keyword args
2010-04-18 22:57:57 +00:00
Benjamin Peterson
0aabda7939
Merged revisions 80129 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r80129 | benjamin.peterson | 2010-04-16 17:52:44 -0500 (Fri, 16 Apr 2010) | 1 line
tiny simplification
........
2010-04-16 23:00:54 +00:00
Benjamin Peterson
ae530c2bab
tiny simplification
2010-04-16 22:52:44 +00:00
Benjamin Peterson
c218ce86c4
Merged revisions 80123-80124,80126 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r80123 | benjamin.peterson | 2010-04-16 17:24:16 -0500 (Fri, 16 Apr 2010) | 1 line
bytearray -> type2test
........
r80124 | benjamin.peterson | 2010-04-16 17:25:57 -0500 (Fri, 16 Apr 2010) | 1 line
fix typo
........
r80126 | benjamin.peterson | 2010-04-16 17:35:38 -0500 (Fri, 16 Apr 2010) | 1 line
have a clear error when passing something > sys.maxsize to bytearray
........
2010-04-16 22:43:53 +00:00
Benjamin Peterson
821a8ea39f
have a clear error when passing something > sys.maxsize to bytearray
2010-04-16 22:35:38 +00:00
Stefan Krah
ef7590e943
Issue #8328 : Silence Visual Studio warnings.
2010-04-07 08:24:44 +00:00
Mark Dickinson
ea7e5510aa
Silence a 'comparison between signed and unsigned integer expressions' gcc warning.
2010-04-06 18:58:54 +00:00
Mark Dickinson
3ec9b942b5
Issue #8259 : Get rid of 'outrageous left shift count' error when
...
left-shifting an integer by more than 2**31 on a 64-bit machine. Also
convert shift counts to a Py_ssize_t instead of a C long.
2010-04-06 16:46:09 +00:00
Mark Dickinson
56506a6ed2
Use a better NaN test in _Py_HashDouble as well.
2010-04-05 18:54:51 +00:00
Mark Dickinson
5e0c2748fb
Use a more robust infinity check in _Py_HashDouble.
...
This fixes a test_decimal failure on FreeBSD 8.0. (modf apparently
doesn't follow C99 Annex F on FreeBSD.)
2010-04-05 18:07:51 +00:00
Raymond Hettinger
30583e3f38
Silence a compiler warning.
2010-04-03 17:10:05 +00:00
Benjamin Peterson
bea424af98
more _PyString_Resize error checking
2010-04-03 00:57:33 +00:00
Benjamin Peterson
6caf7ff505
always check _PyString_Resize for error
...
also normalize how this error is checked
2010-04-02 23:59:41 +00:00
Eric Smith
d44b2fc87c
Issue 7994: Make object.__format__ with a non-empty format string a PendingDecprecationWarning. Still need to remove uses of this from various tests.
2010-04-02 12:30:56 +00:00
Larry Hastings
5ac006dfd3
Capsule-related changes:
...
* PyCObject_AsVoidPtr() can now open capsules. This addresses
most of the remaining backwards-compatibility concerns about
the conversion of Python 2.7 from CObjects to capsules.
* CObjects were marked Pending Deprecation.
* Documentation about this pending deprecation was added to
cobject.h.
* The capsule source files were added to the legacy PC build
processes.
2010-04-02 11:01:35 +00:00
Antoine Pitrou
a57df2cf1d
Issue #8268 : Old-style classes (not just instances) now support weak
...
references.
2010-03-31 21:32:15 +00:00
Florent Xicluna
22b243809e
#7643 : Unicode codepoints VT (0x0B) and FF (0x0C) are linebreaks according to Unicode Standard Annex #14 .
2010-03-30 08:24:06 +00:00
Larry Hastings
402b73fb8d
Backported PyCapsule from 3.1, and converted most uses of
...
CObject to PyCapsule.
2010-03-25 00:54:54 +00:00
Victor Stinner
4fd2ff90a4
Merged revisions 79278,79280 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r79278 | victor.stinner | 2010-03-22 13:24:37 +0100 (lun., 22 mars 2010) | 2 lines
Issue #1583863 : An unicode subclass can now override the __str__ method
........
r79280 | victor.stinner | 2010-03-22 13:36:28 +0100 (lun., 22 mars 2010) | 5 lines
Fix the NEWS about my last commit: an unicode subclass can now override the
__unicode__ method (and not the __str__ method).
Simplify also the testcase.
........
2010-03-22 12:56:39 +00:00
Victor Stinner
95affc4449
Issue #1583863 : An unicode subclass can now override the __str__ method
2010-03-22 12:24:37 +00:00
Collin Winter
001a3952c9
Add support for weak references to code objects. This will be used by an optimization in the incoming Python 3 JIT.
...
Patch by Reid Kleckner!
2010-03-18 21:54:01 +00:00
Florent Xicluna
2e0a53fdf6
Issue #8024 : Update the Unicode database to 5.2
2010-03-18 21:50:06 +00:00
Victor Stinner
17d905449d
Issue #7818 : set().test_c_api() doesn't expect a set('abc'), modify the set.
2010-03-13 00:13:22 +00:00
Ezio Melotti
56f1682a44
Merged revisions 78515-78516,78522 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r78515 | georg.brandl | 2010-02-28 20:19:17 +0200 (Sun, 28 Feb 2010) | 1 line
#8030 : make builtin type docstrings more consistent: use "iterable" instead of "seq(uence)", use "new" to show that set() always returns a new object.
........
r78516 | georg.brandl | 2010-02-28 20:26:37 +0200 (Sun, 28 Feb 2010) | 1 line
The set types can also be called without arguments.
........
r78522 | ezio.melotti | 2010-03-01 01:59:00 +0200 (Mon, 01 Mar 2010) | 1 line
#8030 : more docstring fix for builtin types.
........
2010-03-01 04:05:56 +00:00
Ezio Melotti
fb501123e3
#8030 : more docstring fix for builtin types.
2010-02-28 23:59:00 +00:00
Georg Brandl
b36e63a5ee
The set types can also be called without arguments.
2010-02-28 18:26:37 +00:00
Georg Brandl
bca1169e94
#8030 : make builtin type docstrings more consistent: use "iterable" instead of "seq(uence)", use "new" to show that set() always returns a new object.
2010-02-28 18:19:17 +00:00
Ezio Melotti
85ddea7e69
Merged revisions 78449 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r78449 | ezio.melotti | 2010-02-25 19:36:04 +0200 (Thu, 25 Feb 2010) | 1 line
#7649 : "u'%c' % char" now behaves like "u'%s' % char" and raises a UnicodeDecodeError if 'char' is a byte string that can't be decoded using the default encoding.
........
2010-02-25 17:51:33 +00:00
Ezio Melotti
321251567e
#7649 : "u'%c' % char" now behaves like "u'%s' % char" and raises a UnicodeDecodeError if 'char' is a byte string that can't be decoded using the default encoding.
2010-02-25 17:36:04 +00:00
Eric Smith
66807853b4
Merged revisions 78418 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r78418 | eric.smith | 2010-02-24 09:15:36 -0500 (Wed, 24 Feb 2010) | 1 line
Issue #7309 : Unchecked pointer access when converting UnicodeEncodeError, UnicodeDecodeError, and UnicodeTranslateError to strings.
........
2010-02-24 14:27:37 +00:00
Eric Smith
2d9856d6ce
Issue #7309 : Unchecked pointer access when converting UnicodeEncodeError, UnicodeDecodeError, and UnicodeTranslateError to strings.
2010-02-24 14:15:36 +00:00
Victor Stinner
f7270ba58f
Merged revisions 78392 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r78392 | victor.stinner | 2010-02-24 00:16:07 +0100 (mer., 24 févr. 2010) | 4 lines
Issue #7649 : Fix u'%c' % char for character in range 0x80..0xFF
=> raise an UnicodeDecodeError. Patch written by Ezio Melotti.
........
2010-02-23 23:20:14 +00:00
Victor Stinner
f20f9c299e
Issue #7649 : Fix u'%c' % char for character in range 0x80..0xFF
...
=> raise an UnicodeDecodeError. Patch written by Ezio Melotti.
2010-02-23 23:16:07 +00:00
Eric Smith
87bcb243ac
Issue #6902 : Fix problem with built-in types format incorrectly with 0 padding.
2010-02-23 00:11:16 +00:00
Andrew M. Kuchling
00b6a5c03d
#7706 : DONT_HAVE_ERRNO_H is no longer defined by configure (after rev.46819).
2010-02-22 23:10:52 +00:00
Eric Smith
f32d4acead
Issue #7988 : Fix default alignment to be right aligned for complex.__format__. Now it matches other numeric types.
2010-02-22 18:33:47 +00:00
Ezio Melotti
bce3e17bd2
#7482 : clarify error message in case of division by zero of float and complex numbers.
2010-02-22 16:30:58 +00:00
Mark Dickinson
82b34c5dbe
Issue #5211 : Fix complex type to avoid implicit calls to
...
complex.__coerce__. Thanks Meador Inge for the patch.
2010-02-21 12:57:35 +00:00
Mark Dickinson
a920961673
Merged revisions 78183-78184 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r78183 | mark.dickinson | 2010-02-14 12:16:43 +0000 (Sun, 14 Feb 2010) | 1 line
Silence some 'comparison between signed and unsigned' compiler warnings.
........
r78184 | mark.dickinson | 2010-02-14 12:31:26 +0000 (Sun, 14 Feb 2010) | 1 line
Silence more compiler warnings; fix an instance of potential undefined behaviour from signed overflow.
........
2010-02-14 13:08:35 +00:00
Mark Dickinson
2d7911eda4
Silence more compiler warnings; fix an instance of potential undefined behaviour from signed overflow.
2010-02-14 12:31:26 +00:00
Mark Dickinson
ac5685eb67
Silence some 'comparison between signed and unsigned' compiler warnings.
2010-02-14 12:16:43 +00:00
Antoine Pitrou
2483728850
Merged revisions 77989 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77989 | antoine.pitrou | 2010-02-05 18:05:54 +0100 (ven., 05 févr. 2010) | 6 lines
Issue #5677 : Explicitly forbid write operations on read-only file objects,
and read operations on write-only file objects. On Windows, the system C
library would return a bogus result; on Solaris, it was possible to crash
the interpreter. Patch by Stefan Krah.
........
2010-02-05 17:11:32 +00:00
Antoine Pitrou
bb445a1f22
Issue #5677 : Explicitly forbid write operations on read-only file objects,
...
and read operations on write-only file objects. On Windows, the system C
library would return a bogus result; on Solaris, it was possible to crash
the interpreter. Patch by Stefan Krah.
2010-02-05 17:05:54 +00:00
Antoine Pitrou
526e421b12
Issue #7385 : Fix a crash in `MemoryView_FromObject` when
...
`PyObject_GetBuffer` fails. Patch by Florent Xicluna.
2010-02-02 22:36:17 +00:00
Mark Dickinson
a36507c64c
Issue #7767 : Add new C-API function PyLong_AsLongLongAndOverflow, a
...
long long variant of PyLong_AsLongAndOverflow. Patch by Case Van
Horsen.
2010-01-30 10:08:33 +00:00
Mark Dickinson
0273354ab6
Merged revisions 77821 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77821 | mark.dickinson | 2010-01-29 17:11:39 +0000 (Fri, 29 Jan 2010) | 3 lines
Issue #7788 : Fix a crash produced by deleting a list slice with huge
step value. Patch by Marcin Bachry.
........
2010-01-29 17:16:18 +00:00
Mark Dickinson
36ecd676ea
Issue #7788 : Fix a crash produced by deleting a list slice with huge
...
step value. Patch by Marcin Bachry.
2010-01-29 17:11:39 +00:00
Ezio Melotti
dabb5f7db9
Merged revisions 77743 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77743 | ezio.melotti | 2010-01-25 13:24:37 +0200 (Mon, 25 Jan 2010) | 1 line
#7775 : fixed docstring for rpartition
........
2010-01-25 11:46:11 +00:00
Ezio Melotti
1fafaab5e5
#7775 : fixed docstring for rpartition
2010-01-25 11:24:37 +00:00
Antoine Pitrou
bb667d433c
Merged revisions 77573 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77573 | antoine.pitrou | 2010-01-17 13:26:20 +0100 (dim., 17 janv. 2010) | 6 lines
Issue #7561 : Operations on empty bytearrays (such as `int(bytearray())`)
could crash in many places because of the PyByteArray_AS_STRING() macro
returning NULL. The macro now returns a statically allocated empty
string instead.
........
2010-01-17 12:31:10 +00:00
Antoine Pitrou
e80a6a4ead
Issue #7561 : Operations on empty bytearrays (such as `int(bytearray())`)
...
could crash in many places because of the PyByteArray_AS_STRING() macro
returning NULL. The macro now returns a statically allocated empty
string instead.
2010-01-17 12:26:20 +00:00
Georg Brandl
aee900338e
Add note about usage of STRINGLIB_EMPTY.
2010-01-17 12:14:42 +00:00
Ezio Melotti
262c3ce507
Merged revisions 77487 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77487 | ezio.melotti | 2010-01-14 13:34:10 +0200 (Thu, 14 Jan 2010) | 1 line
Fixed typo
........
2010-01-14 11:39:50 +00:00
Ezio Melotti
d234208588
Fixed typo
2010-01-14 11:34:10 +00:00
Antoine Pitrou
10042922d9
Sanitize bloom filter macros
2010-01-13 14:01:26 +00:00
Antoine Pitrou
a913a20c91
Test commit to try to diagnose failures of the IA-64 buildbot
2010-01-13 13:43:37 +00:00
Antoine Pitrou
5c767c2f87
Fix Windows build (re r77461)
2010-01-13 08:55:20 +00:00
Antoine Pitrou
6467213bfd
Issue #7622 : Improve the split(), rsplit(), splitlines() and replace()
...
methods of bytes, bytearray and unicode objects by using a common
implementation based on stringlib's fast search. Patch by Florent Xicluna.
2010-01-13 07:55:48 +00:00
Alexandre Vassalotti
58a96efde5
Fixed repr of dictionary views.
2010-01-12 01:34:43 +00:00
Alexandre Vassalotti
69eb51697c
Issue #1967 : Backport dictionary views.
2010-01-11 23:17:10 +00:00
Benjamin Peterson
3694366af5
factor out __complex__ lookup code to fix another case
2010-01-04 01:00:47 +00:00
Benjamin Peterson
ecdae19fbe
do correct lookup of the __complex__ method
2010-01-04 00:43:01 +00:00
Antoine Pitrou
5b7139aab4
Issue #7462 : Implement the stringlib fast search algorithm for the `rfind`,
...
`rindex`, `rsplit` and `rpartition` methods. Patch by Florent Xicluna.
2010-01-02 21:12:58 +00:00
Mark Dickinson
d3e323215c
Refactor some longobject internals: PyLong_AsDouble and _PyLong_AsScaledDouble
...
(the latter renamed to _PyLong_Frexp) now use the same core code. The
exponent produced by _PyLong_Frexp now has type Py_ssize_t instead of the
previously used int, and no longer needs scaling by PyLong_SHIFT. This
frees the math module from having to know anything about the PyLong
implementation. This closes issue #5576 .
2010-01-02 14:45:40 +00:00
Mark Dickinson
99d652ef66
Issue #7534 : Fix handling of nans, infinities, and negative zero in **
...
operator, on IEEE 754 platforms. Thanks Marcos Donolo for original patch.
2009-12-30 12:12:23 +00:00
Mark Dickinson
4657283647
Issue #1811 : Improve accuracy and consistency of true division for integers.
2009-12-27 14:55:57 +00:00
Ezio Melotti
e748238a4f
Merged revisions 77045 via svnmerge from
...
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77045 | ezio.melotti | 2009-12-25 00:25:17 +0200 (Fri, 25 Dec 2009) | 1 line
#6108 : unicode(exception) and str(exception) should return the same message
........
2009-12-24 22:32:25 +00:00
Ezio Melotti
f84caf4eda
#6108 : unicode(exception) and str(exception) should return the same message
2009-12-24 22:25:17 +00:00