Struct cpython::NoArgs
[−]
[src]
pub struct NoArgs;
An empty struct that represents the empty argument list.
Corresponds to the empty tuple ()
in Python.
Example
let gil_guard = cpython::Python::acquire_gil(); let py = gil_guard.python(); let os = py.import("os").unwrap(); let pid = os.call(py, "getpid", cpython::NoArgs, None).unwrap();
Trait Implementations
impl Copy for NoArgs
[src]
impl Clone for NoArgs
[src]
fn clone(&self) -> NoArgs
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Debug for NoArgs
[src]
impl ToPyObject for NoArgs
[src]
Converts NoArgs
to an empty Python tuple.
type ObjectType = PyTuple
fn to_py_object(&self, py: Python) -> PyTuple
[src]
Converts self into a Python object.
fn into_py_object(self, py: Python) -> Self::ObjectType where
Self: Sized,
[src]
Self: Sized,
Converts self into a Python object. Read more
fn with_borrowed_ptr<F, R>(&self, py: Python, f: F) -> R where
F: FnOnce(*mut PyObject) -> R,
[src]
F: FnOnce(*mut PyObject) -> R,
Converts self into a Python object and calls the specified closure on the native FFI pointer underlying the Python object. Read more