NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
crates.io · #1142 most downloaded on crates.io
Safely cast bytes slices from/to slices of built-in fundamental numeric types
Last release 2 years ago
no release in 18 months
Ships unpredictably
gaps range from 9 days to 2.3 years
Nearly every release is documented
notes for 14 of 14 stable releases
Nothing withdrawn
no release was ever pulled
9 years old
14 releases · first in 2017
### Changed - Fix tests for Rust 1.81. - Declare Rust 1.51 as MSRV.
Fix a couple of clippy warnings in the tests.
Make trait methods #[inline]. This allows the compiler to make the call a no-op in many cases.
One column per quarter.
#[inline]. This allows the compiler to make the call a
no-op in many cases.Trait impls for converting between &[[T; N]] and &[u8] for specific T.
&[[T; N]] and &[u8] for specific T.ToByteSlice and ToMutByteSlice impl for &[()]. This always produces an empty byte slice.
ToByteSlice and ToMutByteSlice impl for &[()]. This always produces an
empty byte slice.Support for casting between Vec and Vec . This was actually unsound as the alloc trait requires that memory is deallocated with exactly the same align
Vec<T> and Vec<u8>. This was actually
unsound as the alloc trait requires that memory is deallocated with exactly
the same alignment as it was allocated with.usize tests on 16/32 bit architectures.Improve documentation and examples
Support for casting between Vec and Vec
Vec<T> and Vec<u8>### Added - Support for usize and isize
usize and isize### Changed - Add no_std support - Migrate to 2018 edition
no_std supportCasting of empty slices works correctly now instead of failing with an alignment mismatch error.
The Error type now implements Clone.
Error type now implements Clone.AsByteSlice::as_byte_slice and ToByteSlice::to_byte_slice were changed
to always return &[u8] instead of Result<&[u8], Error>.AsMutByteSlice::as_mut_byte_slice and ToMutByteSlice::to_mut_byte_slice
were changed to always return &mut [u8] instead of Result<&mut [u8], Error>.Display impl for Error now produces more detailed error messages.Error enum were renamed.Major refactoring of how the traits work. It is now possible to work directly on AsRef<[T]> and AsMut<[T]>, e.g. on Vec and Box<[T]>.
AsRef<[T]> and AsMut<[T]>, e.g. on Vec<T> and Box<[T]>.Initial release of the byte-slice-cast crate.
byte-slice-cast crate.Your coding agent can read these notes before it upgrades. Set up the MCP server →