[][src]Crate cl_traits

Collection Traits (cl-traits)

Macros

create_and_impl_marker_trait

Creates a marker trait $trait_name with or without bounds.

create_marker_trait

Creates a marker trait $trait_name with or without bounds.

Structs

ArrayWrapper

With const_generics feature, wraps an arbitrary length array. Otherwise, wraps an array with up to 32 elements. Necessary for third-party and std implementations.

Traits

Array

This is my array trait. There are many like it, but this one is mine.

Capacity

Has some sort of storage that holds a maximum number of elements.

Clear

Has some sort of storage that can be cleared.

Length

Has some sort of storage that holds a certain number of elements.

Push

Has some way to push an element into some sort of storage.

Storage

Storage is anything that can hold a collection of items

Swap

Has some way to swap elements of some sort of storage.

Truncate

Has some way to truncate some sort of storage.

WithCapacity

Creates a new instance based on an initial holding capacity.

Functions

create_array

Creates an array [T; N] where each array element T is returned by the cb call.