Skip to content

std::collections::queue

Status: experimental

FIFO queue over Vec. Re-bind shape: let q = queue::push(q, v).

API details and source

The implementation source contains the complete declarations and implementation notes. The table below lists canonical Gossamer call signatures; every item name links directly to its implementation file.

Item Canonical signature or declaration Description
len fn len(xs: Queue<i64>) -> i64 Element count.
peek fn peek(xs: Queue<i64>) -> i64 Front element, or 0 if empty.
pop fn pop(xs: Queue<i64>) -> Queue<i64> Drop the front element; returns the new queue.
push fn push(xs: Queue<i64>, value: i64) -> Queue<i64> Append an i64 to the back; returns the new queue.