SF patch #1458476 with modifications based on discussions in python-dev. This

adds the following API calls: PySet_Clear(), _PySet_Next(), and
_PySet_Update().  The latter two are considered non-public.  Tests and
documentation (for the public API) are included.
This commit is contained in:
Barry Warsaw 2006-03-30 22:45:35 +00:00
parent c259cc9c4c
commit 176014ffad
4 changed files with 75 additions and 6 deletions

View file

@ -421,7 +421,7 @@ class TestSet(TestJointOps):
self.assertRaises(ReferenceError, str, p)
# C API test only available in a debug build
if hasattr(sys, "gettotalrefcount"):
if hasattr(set, "test_c_api"):
def test_c_api(self):
self.assertEqual(set('abc').test_c_api(), True)