Antoine Pitrou
2b0218a259
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 3.2.4
(those which use the trashcan mechanism, despite it being undocumented)
will not be loadable by 3.2.3 and earlier. However, extension modules
compiled for 3.2.3 and earlier will be loadable by 3.2.4.
2012-09-06 00:59:49 +02:00
Antoine Pitrou
721738fbee
Issue #15604 : Update uses of PyObject_IsTrue() to check for and handle errors correctly.
...
Patch by Serhiy Storchaka.
2012-08-15 23:20:39 +02:00
Antoine Pitrou
6f430e4963
Issue #15604 : Update uses of PyObject_IsTrue() to check for and handle errors correctly.
...
Patch by Serhiy Storchaka.
2012-08-15 23:18:25 +02:00
Antoine Pitrou
66a3a7ed10
Try to fix crash on x86 OpenIndiana buildbot.
2012-06-24 00:42:59 +02:00
Antoine Pitrou
1351ca6e66
Replace assert() with a more informative fatal error.
2012-06-24 00:30:12 +02:00
Antoine Pitrou
bb78f57c14
Use struct member (ht_type) instead of casting pointers.
2012-06-24 00:18:27 +02:00
Martin v. Löwis
9c56409d33
Issue #15146 : Add PyType_FromSpecWithBases. Patch by Robin Schreiber.
2012-06-23 23:20:45 +02:00
Antoine Pitrou
99cc629969
Issue #15142 : Fix reference leak when deallocating instances of types created using PyType_FromSpec().
2012-06-23 14:42:38 +02:00
Antoine Pitrou
a4db02c7a3
Issue #15142 : Fix reference leak when deallocating instances of types created using PyType_FromSpec().
2012-06-23 14:45:21 +02:00
Nick Coghlan
0b43bcf528
Close #14857 : fix regression in references to PEP 3135 implicit __class__ closure variable. Reopens issue #12370 , but also updates unittest.mock to workaround that issue
2012-05-27 18:17:07 +10:00
Antoine Pitrou
1b634c266c
Use size_t, not ssize_t (issue #14801 ).
2012-05-14 14:44:37 +02:00
Antoine Pitrou
a1433fed8e
Remove tab characters
2012-05-14 14:43:25 +02:00
Antoine Pitrou
682d94c11a
Use size_t, not ssize_t (issue #14801 ).
2012-05-14 14:43:03 +02:00
Benjamin Peterson
1cffbac2cb
merge 3.2 ( #14752 )
2012-05-08 09:22:45 -04:00
Benjamin Peterson
89a6e9a27b
fix possible refleak ( closes #14752 )
2012-05-08 09:22:24 -04:00
Benjamin Peterson
64acccf46d
decref cached keys on type deallocation ( #13903 )
2012-04-27 15:07:36 -04:00
Martin v. Loewis
4f2f3b6217
Account for shared keys in type's __sizeof__ ( #13903 ).
2012-04-24 19:13:57 +02:00
Benjamin Peterson
42f58818d6
merge 3.2 ( #14658 )
2012-04-24 11:09:20 -04:00
Benjamin Peterson
7b1668735a
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
7d95e40721
Implement PEP 412: Key-sharing dictionaries ( closes #13903 )
...
Patch from Mark Shannon.
2012-04-23 11:24:50 -04:00
Benjamin Peterson
9ee601e197
merge 3.2
2012-04-01 18:51:37 -04:00
Benjamin Peterson
b6af60c2a9
adjust formatting
2012-04-01 18:49:54 -04:00
Benjamin Peterson
3471bb67e7
remove extraneous condition
2012-04-01 18:48:40 -04:00
Benjamin Peterson
ab3c1c1994
be consistent with rest of function
2012-04-01 18:48:02 -04:00
Victor Stinner
3c1e48176e
Issue #14383 : Add _PyDict_GetItemId() and _PyDict_SetItemId() functions
...
These functions simplify the usage of static constant Unicode strings.
Generalize the usage of _Py_Identifier in ceval.c and typeobject.c.
2012-03-26 22:10:51 +02:00
Benjamin Peterson
96384b93aa
make extra arguments to object.__init__/__new__ to errors in most cases (finishes #1683368 )
2012-03-17 00:05:44 -05:00
Benjamin Peterson
9a03ecfa50
simply this slightly
2012-03-16 20:15:54 -05:00
Benjamin Peterson
de394543b4
merge 3.2 ( #14334 )
2012-03-16 09:35:38 -05:00
Benjamin Peterson
16d84ac355
check to make sure the attribute is a string ( #14334 )
2012-03-16 09:32:59 -05:00
Victor Stinner
d74782b0ac
Close #14199 : _PyType_Lookup() and super_getattro() keep a strong reference to
...
the type MRO to avoid a crash if the MRO is changed during the lookup.
2012-03-09 00:39:08 +01:00
Benjamin Peterson
9a6338651e
merge 3.2 (#3787e896dbe9)
2012-03-07 18:52:52 -06:00
Benjamin Peterson
52c424343d
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
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__().
2012-02-25 01:22:36 +01:00
Benjamin Peterson
006c5a2235
check for NULL to fix segfault
2012-02-19 20:36:12 -05:00
Benjamin Peterson
8eb1269c34
add generic implementation of a __dict__ descriptor for C types
2012-02-19 19:59:10 -05:00
Benjamin Peterson
2372bb0722
merge 3.2 ( closes #13908 )
2012-01-29 20:17:07 -05:00
Benjamin Peterson
2652d2570e
ready types returned from PyType_FromSpec
2012-01-29 20:16:37 -05:00
Benjamin Peterson
e28108cbd7
adjust declaration
2012-01-29 20:13:18 -05:00
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.
2012-01-22 11:24:29 -05:00
Antoine Pitrou
5b62942074
Issue #13577 : Built-in methods and functions now have a __qualname__.
...
Patch by sbt.
2011-12-23 12:40:16 +01:00
Antoine Pitrou
d73a9acb63
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:17:36 +01:00
Antoine Pitrou
2e872082f6
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
Florent Xicluna
aa6c1d240f
Issue #13575 : there is only one class type.
2011-12-12 18:54:29 +01:00
Antoine Pitrou
86a36b500a
PEP 3155 / issue #13448 : Qualified name for classes and functions.
2011-11-25 18:56:07 +01:00
Eli Bendersky
e92ff0503c
Issue #13161 : fix doc strings of __i*__ operators. Closes #13161
2011-11-11 17:02:16 +02:00
Eli Bendersky
d3baae73be
Issue #13161 : fix doc strings of __i*__ operators
2011-11-11 16:57:05 +02:00
Martin v. Löwis
d10759f6ed
Make _PyUnicode_FromId return borrowed references.
...
http://mail.python.org/pipermail/python-dev/2011-November/114347.html
2011-11-07 13:00:05 +01:00
Nick Coghlan
de31b191e5
Issue 1294232: Fix errors in metaclass calculation affecting some cases of metaclass inheritance. Patch by Daniel Urban.
2011-10-23 22:04:16 +10:00
Nick Coghlan
9715d26305
Merge issue 1294232 patch from 3.2
2011-10-23 22:36:42 +10:00
Martin v. Löwis
bd928fef42
Rename _Py_identifier to _Py_IDENTIFIER.
2011-10-14 10:20:37 +02:00