polars_core::series::arithmetic::checked

Trait NumOpsDispatchCheckedInner

Source
pub trait NumOpsDispatchCheckedInner: PolarsDataType + Sized {
    // Provided methods
    fn checked_div(
        lhs: &ChunkedArray<Self>,
        rhs: &Series,
    ) -> PolarsResult<Series> { ... }
    fn checked_div_num<T: ToPrimitive>(
        lhs: &ChunkedArray<Self>,
        _rhs: T,
    ) -> PolarsResult<Series> { ... }
}
Available on crate feature checked_arithmetic only.

Provided Methods§

Source

fn checked_div(lhs: &ChunkedArray<Self>, rhs: &Series) -> PolarsResult<Series>

Checked integer division. Computes self / rhs, returning None if rhs == 0 or the division results in overflow.

Source

fn checked_div_num<T: ToPrimitive>( lhs: &ChunkedArray<Self>, _rhs: T, ) -> PolarsResult<Series>

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§