rawpnt

Trait PointExt

Source
pub trait PointExt: Copy {
    // Required method
    unsafe fn offset(self, i: isize) -> Self;

    // Provided methods
    unsafe fn add(self, i: usize) -> Self { ... }
    unsafe fn sub(self, i: usize) -> Self { ... }
    unsafe fn preinc(&mut self) -> Self { ... }
    unsafe fn postinc(&mut self) -> Self { ... }
    unsafe fn predec(&mut self) -> Self { ... }
    unsafe fn postdec(&mut self) -> Self { ... }
    unsafe fn inc(&mut self) { ... }
    unsafe fn dec(&mut self) { ... }
    unsafe fn strideoffset(self, s: isize, index: usize) -> Self { ... }
}

Required Methods§

Source

unsafe fn offset(self, i: isize) -> Self

Provided Methods§

Source

unsafe fn add(self, i: usize) -> Self

Source

unsafe fn sub(self, i: usize) -> Self

Source

unsafe fn preinc(&mut self) -> Self

Source

unsafe fn postinc(&mut self) -> Self

Source

unsafe fn predec(&mut self) -> Self

Source

unsafe fn postdec(&mut self) -> Self

Source

unsafe fn inc(&mut self)

Source

unsafe fn dec(&mut self)

Source

unsafe fn strideoffset(self, s: isize, index: usize) -> Self

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.

Implementations on Foreign Types§

Source§

impl<T> PointExt for *const T

Source§

unsafe fn offset(self, i: isize) -> Self

Source§

unsafe fn add(self, i: usize) -> Self

Source§

unsafe fn sub(self, i: usize) -> Self

Source§

impl<T> PointExt for *mut T

Source§

unsafe fn offset(self, i: isize) -> Self

Source§

unsafe fn add(self, i: usize) -> Self

Source§

unsafe fn sub(self, i: usize) -> Self

Source§

impl<T> PointExt for NonNull<T>

Source§

unsafe fn offset(self, i: isize) -> Self

Implementors§