Trait PyComplexMethods
pub trait PyComplexMethods<'py>: Sealed {
// Required methods
fn real(&self) -> f64 ⓘ;
fn imag(&self) -> f64 ⓘ;
fn abs(&self) -> f64 ⓘ;
fn pow(&self, other: &Bound<'py, PyComplex>) -> Bound<'py, PyComplex>;
}
Available on crate features
dep_pyo3
and std
only.Expand description
Implementation of functionality for PyComplex
.
These methods are defined for the Bound<'py, PyComplex>
smart pointer, so to use method call
syntax these methods are separated into a trait, because stable Rust does not yet support
arbitrary_self_types
.