Struct std::Queue
generic<T> struct Queue {
?&heap T data;
unsigned long head;
unsigned long len;
unsigned long cap;
}Fields
index of the front element
element count
0 or a power of two
Methods
empty, no allocation
room for cap elements
0 on OOM
null if empty
null if empty
null if empty
drop every element, keep the buffer
Re-lays the ring out linearly (front at index 0) in a buffer of max(8, n) slots rounded up to a power of two.
drops the elements, frees the buffer (Drop)
= drop()