(&self, py: Python)
| 254 | /// This is equivalent to the Python expression: 'hash(self)' |
| 255 | #[inline] |
| 256 | fn hash(&self, py: Python) -> PyResult<crate::Py_hash_t> { |
| 257 | let v = unsafe { ffi::PyObject_Hash(self.as_ptr()) }; |
| 258 | if v == -1 { |
| 259 | Err(PyErr::fetch(py)) |
| 260 | } else { |
| 261 | Ok(v) |
| 262 | } |
| 263 | } |
| 264 | |
| 265 | /// Returns whether the object is considered to be true. |
| 266 | /// This is equivalent to the Python expression: 'not not self' |
nothing calls this directly
no test coverage detected