Crate atlist_rs[][src]

A LinkedList which is allowed to insert/remove element by immutable iterator. Adding, removing and moving the elements within the list or across several lists does not invalidate the iterators or references. An iterator is invalidated only when the corresponding element is deleted.

Example

extern crate atlist_rs;

use atlist_rs::LinkedList;

fn main() {
        let mut l = LinkedList::new();
        let _ = l.push_back(3);
        let _ = l.push_front(2);

        assert_eq!(l.len(), 2);
        assert_eq!(*l.front().unwrap(), 2);
        assert_eq!(*l.back().unwrap(), 3);
}

Structs

Iter

An iterator over the elements of a LinkedList.

IterMut

A mutable iterator over the elements of a LinkedList.

LinkedList

A doubly-linked list in which the liftime of iterator is independent from self.

Enums

LinkedListError

Type Definitions

LinkedListItem
LinkedListResult