Skip to main content

Nullable

Trait Nullable 

Source
pub trait Nullable: Delta {
    const NULL: Self;
}
Expand description

A index which can contain null

§Safety

fn for_all_a(a: *mut u8) {
    assert_eq!(a, <Self as Delta>::add(Self::NULL, a));
    assert_eq!(Self::NULL, <Self as Delta>::sub(a, a));
    assert_eq!(Self::NULL, <Self as Delta>::sub_unchecked(a, a));
}

Required Associated Constants§

Source

const NULL: Self

The value No change in two pointer locations,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl Nullable for i8

Source§

const NULL: Self = 0

Source§

impl Nullable for i16

Source§

const NULL: Self = 0

Source§

impl Nullable for i32

Source§

const NULL: Self = 0

Source§

impl Nullable for i64

Source§

const NULL: Self = 0

Source§

impl Nullable for i128

Source§

const NULL: Self = 0

Source§

impl Nullable for isize

Source§

const NULL: Self = 0

Implementors§