Releases: bodil/sized-chunks
Releases · bodil/sized-chunks
0.7.0
0.6.5
0.6.4
FIXED
InlineArray
can be used in recursive types again.
CHANGED
InlineArray::new()
now panics when it can't store elements with large alignment (this was UB prior to 0.6.3). Alignments ofusize
and smaller are always supported. Larger alignments are supported if the capacity-providing type has sufficient alignment.
0.6.3
FIXED
- Multiple soundness fixes:
InlineArray
handles large alignment, panic safety inChunk
'sclone
andfrom_iter
, capacity checks inunit()
,pair()
andfrom()
. InlineArray
can now handle zero sized values. This relies on conditionals in const functions, a feature which was introduced in Rust 1.46.0, which means this is now the minimum Rust version this crate will work on.
0.6.2
0.6.1
0.6.0
CHANGED
RingBuffer
and its accompanying slice typesSlice
andSliceMut
now implementArray
andArrayMut
fromarray-ops
, giving them most of the methods that would be available on primitive slice types and cutting down on code duplication in the implementation, but at the price of having to pullArray
et al into scope when you need them. Because this means adding a dependency toarray-ops
,RingBuffer
has now been moved behind theringbuffer
feature flag.Chunk
andInlineArray
don't and won't implementArray
, because they are both able to implementDeref<[A]>
, which provides the same functionality more efficiently.
ADDED
- The
insert_from
andinsert_ordered
methods recently added toChunk
have now also been added toRingBuffer
. RingBuffer
'sSlice
andSliceMut
now also have the threebinary_search
methods regular slices have.SparseChunk
,RingBuffer
,Slice
andSliceMut
now have unsafeget_unchecked
andget_unchecked_mut
methods.PartialEq
implementations allowing you to compareRingBuffer
s,Slice
s andSliceMut
s interchangeably have been added.
FIXED
- Fixed an aliasing issue in
RingBuffer
's mutable iterator, as uncovered by Miri. Behind the scenes, the full non-fuzzing unit test suite is now able to run on Miri without crashing it (after migrating the last Proptest tests away from the test suite into the fuzz targets), and this has been included in its CI build. (#6)
0.5.3
0.5.2
ADDED
Chunk
now has aninsert_from
method for inserting multiple values at an index in one go.Chunk
now also has aninsert_ordered
method for inserting values into a sorted chunk.SparseChunk
now has the methodsoption_iter()
,option_iter_mut()
andoption_drain()
with their corresponding iterators to iterate over a chunk as if it were an array ofOption
s.Arbitrary
implementations for all data types have been added behind thearbitrary
feature flag.