| 200 | } |
| 201 | |
| 202 | PyObject *JSObjectProxyMethodDefinitions::JSObjectProxy_richcompare(JSObjectProxy *self, PyObject *other, int op) |
| 203 | { |
| 204 | if (op != Py_EQ && op != Py_NE) { |
| 205 | Py_RETURN_NOTIMPLEMENTED; |
| 206 | } |
| 207 | |
| 208 | std::unordered_map<PyObject *, PyObject *> visited; |
| 209 | |
| 210 | bool isEqual = JSObjectProxy_richcompare_helper(self, other, visited); |
| 211 | switch (op) |
| 212 | { |
| 213 | case Py_EQ: |
| 214 | return PyBool_FromLong(isEqual); |
| 215 | case Py_NE: |
| 216 | return PyBool_FromLong(!isEqual); |
| 217 | default: |
| 218 | return NULL; |
| 219 | } |
| 220 | } |
| 221 | |
| 222 | bool JSObjectProxyMethodDefinitions::JSObjectProxy_richcompare_helper(JSObjectProxy *self, PyObject *other, std::unordered_map<PyObject *, PyObject *> &visited) |
| 223 | { |
nothing calls this directly
no outgoing calls
no test coverage detected