pub fn import(py: Python, name: &CStr) -> PyResult<*const c_void> {
        let caps_ptr = unsafe { PyCapsule_Import(name.as_ptr(), 0) };
        if caps_ptr.is_null() {
            return Err(PyErr::fetch(py));
        }
        Ok(caps_ptr)
    }
/// Retrieves the contents of a capsule as a void pointer by its name.
///
/// This is suitable in particular for later conversion as a function pointer
/// with `mem::transmute`, for architectures where data and function pointers have
/// the same size (see details about this in the
/// [documentation](https://doc.rust-lang.org/std/mem/fn.transmute.html#examples)
/// of the Rust standard library).
Retrieves the contents of a capsule as a void pointer by its name.
This is suitable in particular for later conversion as a function pointer
with `mem::transmute`, for architectures where data and function pointers have
the same size (see details about this in the
[documentation]
of the Rust standard library).
Retrieves the contents of a capsule as a void pointer by its name . This is suitable in particular for later conversion as a function pointer with ` mem :: transmute ` for architectures where data and function pointers have the same size ( see details about this in the [ documentation ] of the Rust standard library ) .
pub fn import(py: Python, name: &CStr) -> PyResult<*const c_void> {
        let caps_ptr = unsafe { PyCapsule_Import(name.as_ptr(), 0) };
        if caps_ptr.is_null() {
            return Err(PyErr::fetch(py));
        }
        Ok(caps_ptr)
    }
pub fn import ( py : Python , name : & CStr ) -> PyResult < * const c_void > { let caps_ptr = unsafe { PyCapsule_Import ( name . as_ptr ( ) , 0 ) } ; if caps_ptr . is_null ( ) { return Err ( PyErr :: fetch ( py ) ) ; } Ok ( caps_ptr ) }
Retrieves the contents of a capsule as a void pointer by its name.
Retrieves the contents of a capsule as a void pointer by its name .
py
Python
name
&CStr
py
Python
name
&CStr