Module slice

Module slice 

Source
Available on crate feature core only.
Expand description

A view into a sequence of values in memory.

Structs§

NSTDSlice
An immutable view into a sequence of values in memory.
NSTDSliceMut
A view into a sequence of values in memory.

Functions§

nstd_core_slice_align
Returns the alignment of each value in a slice.
nstd_core_slice_as_ptr
Returns a raw pointer to the slice’s memory.
nstd_core_slice_empty
Creates a new empty slice with a given stride.
nstd_core_slice_first
Returns an immutable pointer to the first element in the slice.
nstd_core_slice_get
Returns an immutable pointer to the element at index pos in slice.
nstd_core_slice_last
Returns an immutable pointer to the last element in the slice.
nstd_core_slice_len
Returns the number of elements in an immutable slice.
nstd_core_slice_mut_align
Returns the alignment of each value in a slice.
nstd_core_slice_mut_as_const
Creates an immutable version of a mutable slice.
nstd_core_slice_mut_as_ptr
Returns a raw pointer to the slice’s memory.
nstd_core_slice_mut_as_ptr_const
Returns an immutable raw pointer to the slice’s memory.
nstd_core_slice_mut_copy
Copies data into dest from src. The number of bytes copied is determined by src.
nstd_core_slice_mut_empty
Creates a new empty slice with a given stride.
nstd_core_slice_mut_first
Returns a pointer to the first element in the slice.
nstd_core_slice_mut_first_const
Returns an immutable pointer to the first element in the slice.
nstd_core_slice_mut_get
Returns a pointer to the element at index pos in slice.
nstd_core_slice_mut_get_const
Returns an immutable pointer to the element at index pos in slice.
nstd_core_slice_mut_last
Returns a pointer to the last element in the slice.
nstd_core_slice_mut_last_const
Returns an immutable pointer to the last element in the slice.
nstd_core_slice_mut_len
Returns the number of elements in a slice.
nstd_core_slice_mut_new
Creates a new slice from raw data.
nstd_core_slice_mut_new_unchecked
Creates a new slice from raw data without checking if ptr is null.
nstd_core_slice_mut_stride
Returns the amount of bytes each value in a slice occupies.
nstd_core_slice_new
Creates a new slice from raw data.
nstd_core_slice_new_unchecked
Creates a new slice from raw data without checking if ptr is null.
nstd_core_slice_stride
Returns the amount of bytes each value in a slice occupies.

Type Aliases§

NSTDOptionalSlice
Represents an optional value of type NSTDSlice.
NSTDOptionalSliceMut
Represents an optional value of type NSTDSliceMut.