Commit 0b711406 authored by Antoine Pitrou's avatar Antoine Pitrou

Move __Pyx_PySet_ContainsUnhashable into non-proto section

parent b16c07dc
......@@ -1037,6 +1037,19 @@ static CYTHON_INLINE int __Pyx_PyDict_ContainsTF(PyObject* item, PyObject* dict,
/////////////// PySetContains.proto ///////////////
static int __Pyx_PySet_ContainsUnhashable(PyObject *set, PyObject *key); /* proto */
static CYTHON_INLINE int __Pyx_PySet_ContainsTF(PyObject* key, PyObject* set, int eq) {
int result = PySet_Contains(set, key);
if (unlikely(result < 0)) {
result = __Pyx_PySet_ContainsUnhashable(set, key);
}
return unlikely(result < 0) ? result : (result == (eq == Py_EQ));
}
/////////////// PySetContains ///////////////
static int __Pyx_PySet_ContainsUnhashable(PyObject *set, PyObject *key) {
int result = -1;
if (PySet_Check(key) && PyErr_ExceptionMatches(PyExc_TypeError)) {
......@@ -1052,15 +1065,6 @@ static int __Pyx_PySet_ContainsUnhashable(PyObject *set, PyObject *key) {
return result;
}
static CYTHON_INLINE int __Pyx_PySet_ContainsTF(PyObject* key, PyObject* set, int eq) {
int result = PySet_Contains(set, key);
if (unlikely(result < 0)) {
result = __Pyx_PySet_ContainsUnhashable(set, key);
}
return unlikely(result < 0) ? result : (result == (eq == Py_EQ));
}
/////////////// PySequenceContains.proto ///////////////
static CYTHON_INLINE int __Pyx_PySequence_ContainsTF(PyObject* item, PyObject* seq, int eq) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment