MCPcopy Create free account
hub / github.com/dgrunwald/rust-cpython / PyExceptionInstance_Check

Function PyExceptionInstance_Check

python27-sys/src/pyerrors.rs:41–44  ·  view source on GitHub ↗
(x: *mut PyObject)

Source from the content-addressed store, hash-verified

39
40#[inline]
41pub unsafe fn PyExceptionInstance_Check(x: *mut PyObject) -> c_int {
42 (PyInstance_Check(x) != 0
43 || PyType_FastSubclass((*x).ob_type, Py_TPFLAGS_BASE_EXC_SUBCLASS) != 0) as c_int
44}
45
46#[inline]
47pub unsafe fn PyExceptionClass_Name(x: *mut PyObject) -> *const c_char {

Callers

nothing calls this directly

Calls 2

PyInstance_CheckFunction · 0.85
PyType_FastSubclassFunction · 0.70

Tested by

no test coverage detected