All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
PartialEq
implementations to Vec
where Vec
is the RHSheapless::String
is in bytes, not charactersVec::insert(index, element)
Vec::remove(index)
Vec::retain(f)
Vec::retain_mut(f)
IndexSet
and IndexMap
's default
method now compile time checks that their capacity is a power of two.into_vec
to BinaryHeap
entry
API to IndexMap
IntoIterator
trait for Indexmap
FromIterator
for String
first
and last
methods to IndexMap
and IndexSet
pop_{front_back}_unchecked
methods to Deque
Vec::clone
riscv32i
and riscv32imc
targets unconditionally (e.g. build --no-default-features
) depends on atomic-polyfill
pool
example in docstring.Vec::truncate()
, Vec::swap_remove_unchecked()
, and Hole::move_to()
(internal to the binary heap implementation).BinaryHeap
elements are being dropped twicecargo test
can now run on non-x86
hostsOldestOrdered
iterator for HistoryBuffer
atomic-polyfill
is now enabled and used for cas
atomic emulation on riscv
targetsIndexMap
and IndexSet
boundsIndexSet::new()
a const fn
defmt
versions is now supported (0.2
and 0.3
)Pool
is Sync
on ARMv6ArcPool
Debug
impl for Deque
Pool
now works correctlypool!
on thumbv6Pool
on x86SortedLinkedList
Vec::is_empty
, one does not need to go through a slice anymoreVec::pop_unchecked
is now publicDefault
for MpMcQueue
, Queue
and HistoryBuffer
PartialOrd
and Ord
for Vec
and String
Deque
Box::freeze
is deprecated due to possibility of undefined behavior.Vec::into_array
methoddefmt
for Vec
and String
const generics
MVPHistoryBuffer
is now working with const constructors and non-Copy
dataHistoryBuffer::as_slice
and others now only return initialized valuesDeref
, AsRef
and Debug
for HistoryBuffer
MultiCore
/SingleCore
and Uxx
is now removed from spsc::Queue
spsc::Queue
is now usize
onlyspsc::Queue
now sacrifices one element for correctness (see issue #207), i.e. it creates an N - 1
sized queue instead of the old that generated an size N
queueString
has had utf8
related methods removed as this can be done via str
AsSlice
traits any more, now using AsRef
and AsMut
as they work with any size of array nowPool
and MPMC
now works on thumbv6m
IndexMap::new()
is now a const-fn
generic-array
dependency has been bumped to v0.14.2.as_mut_vec
for String
set_len
for Vec
histbuf
Producer
was made Send
for single core applicationsHistoryBuffer
Vec
: from_slice
, starts_with
, ends_with
ufmt
support for String
and Vec
pool
support for bare-metal armebv7r-
targetspool
for x86
StableDeref
implementation for pool::Box
and pool::singleton::Box
.Pool
support to the bare-metal armv7a-
targets.mpmc::Queue::dqueue
that led to an infinite loopspsc::Queue
iterators now implement the double ended iterator traitopt-out cas
feature to disable parts of the API that use CAS instructions. Useful if using a custom (i.e. not built-in) rustc target that does not have CAS instructions.
singleton Pool
support on ARMv7-A devices
Queue::peek
BinaryHeap::peek_mut
Pool
now implements the Sync
trait when targeting ARMv7-R.
Most data structures can now be constructed in “const context” (e.g. static [mut]
variables) using a newtype in heapless::i
.
Pool
has gained a grow_exact
method to more efficiently use statically allocated memory.
The pool!
macro now accepts attributes.
mpmc::Q*
a family of fixed capacity multiple-producer multiple-consumer lock-free queues.
binary_heap::Kind
is now a sealed trait.[breaking-change] The “smaller-atomics” feature has been removed. It is now always enabled.
[breaking-change] The “min-const-fn” feature has been removed. It is now always enabled.
[breaking-change] The MSRV has been bumped to Rust 1.36.0.
[breaking-change] The version of the generic-array
dependency has been bumped to v0.13.0.
PartialEq
, PartialOrd
, Eq
, Ord
and Hash
for pool::Box
and pool::singleton::Box
.core::mem::MaybeUninit
that occurred when using some of our data structures with types that implement Drop
.Added a memory pool that's lock-free and interrupt-safe on the ARMv7-M architecture.
IndexMap
have gained Eq
and PartialEq
implementations.
All containers now implement Clone
spsc::Queue
now implements Debug
, Hash
, PartialEq
and Eq
LinearMap
now implements Debug
, FromIterator
, IntoIter
, PartialEq
, Eq
and Default
BinaryHeap
now implements Debug
and Default
String
now implements FromStr
, Hash
, From<uxx>
and Default
Vec
now implements Hash
and Default
A “serde” Cargo feature that when enabled adds a serde::Serialize
and serde::Deserialize
implementations to each collection.
spsc::Queue
that indicates whether the queue is only single-core safe, or multi-core safe. By default the queue is multi-core safe; this preserves the current semantics. New unsafe
constructors have been added to create the single-core variant.[breaking-change] All Cargo features are disabled by default. This crate now compiles on stable by default.
[breaking-change] RingBuffer has been renamed to spsc::Queue. The ring_buffer module has been renamed to spsc.
[breaking-change] The bounds on spsc::Queue have changed.
Uxx
trait has been removed from the public API.IntoIterator
and FromIterator
for Vec
ready
methods to ring_buffer::{Consumer,Producer}
const
functions into normal functions when disabled.RingBuffer
when disabled.RingBuffer.len
functionRingBuffer
. It should be the requested capacity plus not twice that plus one.RingBuffer.enqueue_unchecked
an unchecked version of RingBuffer.enqueue
BinaryHeap.pop_unchecked
an unchecked version of BinaryHeap.pop
BinaryHeap.push_unchecked
an unchecked version of BinaryHeap.push
generic_array::ArrayLength
, for convenience.IndexMap
and IndexSet
.Extend
implementation to Vec
PartialEq
implementations to Vec
[breaking-change] The capacity of all data structures must now be specified using type level integers (cf. typenum
). See documentation for details.
[breaking-change] BufferFullError
has been removed in favor of (a) returning ownership of the item that couldn't be added to the collection (cf. Vec.push
), or (b) returning the unit type when the argument was not consumed (cf. Vec.extend_from_slice
).
RingBuffer
via the Consumer
and Producer
end points.RingBuffer
now has a generic index type, which default to usize
for backward compatibility. Changing the index type to u8
or u16
reduces the footprint of the RingBuffer
but limits its maximum capacity (254 and 65534, respectively).BinaryHeap
implementation. BinaryHeap
is a priority queue implemented with a binary heap.heapless::Vec
no longer incurs in a bounds check.LinerMap::new
is now a const fnswap_remove
method to Vec
LinearMap
implementation. LinearMap
is a map / dict backed by an array and that performs lookups via linear search.std::String
Vec
now implements both fmt::Debug
, PartialEq
and Eq
.
resize
and resize_default
methods to Vec
.
A single producer single consumer mode to RingBuffer
.
A truncate
method to Vec
.
[breaking-change] Both Vec::new
and RingBuffer::new
no longer require an initial value. The signature of new
is now const fn() -> Self
.
[breaking-change] The error type of all operations that may fail has changed from ()
to BufferFullError
.
Both RingBuffer
and Vec
now support arrays of any size for their backup storage.