Module list

Source
Expand description

A linked list implementation.

Macros§

define_list_arc_field_getter
Defines getters for a ListArcField.
impl_has_list_links
Implements the HasListLinks trait for the given type.
impl_has_list_links_self_ptr
Implements the HasListLinks and HasSelfPtr traits for the given type.
impl_list_arc_safe
Declares that this type supports ListArc.
impl_list_item
Implements the ListItem trait for the given type.

Structs§

AtomicTracker
A utility for tracking whether a ListArc exists using an atomic.
Cursor
A cursor into a List.
CursorPeek
References the element in the list next to the cursor.
IntoIter
An owning iterator into a List.
Iter
An iterator over a List.
List
A linked list.
ListArc
A wrapper around Arc that’s guaranteed unique for the given id.
ListArcField
A field owned by a specific ListArc.
ListLinks
The prev/next pointers for an item in a linked list.
ListLinksSelfPtr
Similar to ListLinks, but also contains a pointer to the full value.

Traits§

HasListLinks
Declares that this type has a ListLinks<ID> field at a fixed offset.
HasSelfPtr
Declares that the ListLinks<ID> field in this struct is inside a ListLinksSelfPtr<T, ID>.
ListArcSafe
Declares that this type has some way to ensure that there is exactly one ListArc instance for this id.
ListItem
Implemented by types where a ListArc<Self> can be inserted into a List.
TryNewListArc
Declares that this type is able to safely attempt to create ListArcs at any time.