v0.1006.0
Pre-release
Pre-release
mumbleskates
released this
15 Apr 03:18
·
195 commits
to bilrost
since this release
v0.1006.0
Breaking changes
- The (unstable) internal encoding traits continue to evolve, now varying the
implementation ofTagMeasurer
and moving the "allow empty" argument of
distinguished value decoding into a const generic param.
New features
- Hash maps and hash sets can now have any kind of hasher, as long as the
BuildHasher
implementsDefault
. - Plain tuples can now be encoded as message fields! Tuples encode exactly the
same as messages with field tags 0 through N-1, but the encoding of each field
in the tuple can be specified. See the readme for more information. - Fixed-size arrays (
[T; N]
) can now also be encoded as message fields. Arrays
encode exactly the same as a collection likeVec
would, except if each value
in the array is empty the whole array is considered empty. When decoding an
array, if a nonzero number of items is present and it is not the same number
of items as the size of the array, the value and message being decoded are
considered to be invalid. - A couple third-party alternative types for
Vec
that have bounded size and
inline-only storage (ArrayVec
from thearrayvec
andtinyvec
crates) have
been added. - Third-party alternative types for
Vec
now also work withu8
items and the
plainbytes
encoding.
Fixes
- Added a
Self: Default
bound to the impl forMessage
when there are ignored
fields. This means that it can be possible to have a message type with ignored
fields and generically typed fields that don't implementDefault
; rather
than failing to compile, it will now simply not implementMessage
.
Cleanups
- Consolidated (almost) all the standard impls of the
EmptyState
trait into
the same module.