diff options
author | Raymond Hettinger <python@rcn.com> | 2003-12-13 11:58:56 (GMT) |
---|---|---|
committer | Raymond Hettinger <python@rcn.com> | 2003-12-13 11:58:56 (GMT) |
commit | d3ae6729e7e04d505c29450aed7ef64343ec9eb1 (patch) | |
tree | d1a61cd00a2e992255c79257c3ed82d04555b3ff /Objects | |
parent | 8f5cdaa784f555149adf5e94fd2e989f99d6b1db (diff) | |
download | cpython-d3ae6729e7e04d505c29450aed7ef64343ec9eb1.zip cpython-d3ae6729e7e04d505c29450aed7ef64343ec9eb1.tar.gz cpython-d3ae6729e7e04d505c29450aed7ef64343ec9eb1.tar.bz2 |
Use PyDict_Contains() instead of PySequence_Contains().
Diffstat (limited to 'Objects')
-rw-r--r-- | Objects/descrobject.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Objects/descrobject.c b/Objects/descrobject.c index ec4ea56..7d523cf 100644 --- a/Objects/descrobject.c +++ b/Objects/descrobject.c @@ -690,7 +690,7 @@ static PyMappingMethods proxy_as_mapping = { static int proxy_contains(proxyobject *pp, PyObject *key) { - return PySequence_Contains(pp->dict, key); + return PyDict_Contains(pp->dict, key); } static PySequenceMethods proxy_as_sequence = { @@ -709,7 +709,7 @@ static PySequenceMethods proxy_as_sequence = { static PyObject * proxy_has_key(proxyobject *pp, PyObject *key) { - int res = PySequence_Contains(pp->dict, key); + int res = PyDict_Contains(pp->dict, key); if (res < 0) return NULL; return PyBool_FromLong(res); |