- Add
message::Reader::get_segments()
method.
- Fix bug where
ptr::copy_nonoverlapping()
was potentially being called on invalid pointers (with length = 0).
- Add support for downcasting dynamic values to fully concrete list and struct types.
- Add trait hook support for streaming RPC methods.
- Add
unsafe impl Sync
to BuilderArenaImpl. - Move
unsafe impl Send
from message::Builder to BuilderArenaImpl. - Fix misspelled error variant: UnexepectedFarPointer -> UnexpectedFarPointer.
- Add
Results::set_pipeline()
andResultsHook::set_pipeline()
.
- Fix ExactSizeIterator implementations so that they return the number of remaining elements instead of the total length of the underlying list.
- Fix bug in dynamic reflection where
get_named()
andhas_named()
could panic on a field that is not present in the schema.
- Fix possible undefined behavior in primitive_list::as_slice() on empty lists.
- Disable primitive_list::as_slice() when T is larger than one byte and the
unaligned
feature is enabled. - Enable primitive_list::as_slice() for big-endian targets when T is at most one byte.
- Rename ReadSegmentTableResult to NoAllocSegmentTableInfo and make it public.
- Rename NoAllocBufferSegments::from_segment_table() to NoAllocBufferSegments::from_segment_table_info() and make it public.
- Revert SingleSegmentAllocator generalization because it was unsound.
- Implement SetterInputtext::Owned for all T : AsRef.
- Use binary search instead of linear scan in DynamicStruct::get_named().
- Rename SetPointerBuilder to SetterInput.
- Add Receiver type parameter to SetterInput.
- Support setting text fields by text::Reader or &str, via the SetterInput tactic. This will break code that uses the into() to convert from str to text::Reader in the arguments of such methods.
- Also support setting primitive list fields by native Rust slices, and text list fields by slices of AsRef.
- Update embedded-io dependency to version 0.6.1.
- Use AsRef<[u8]> instead of Deref<Target=[u8]> in NoAllocBufferSegments.
- Generalize SingleSegmentAllocator to take any type that implements AsMut<[u8]>.
- Add PartialEq impls for text::Reader <-> String.
- Regenerate schema_capnp.rs after fixing overly-restrictive lifetimes for struct lists.
- Add PartialOrd impls for text::Reader.
- Add Debug impl for primitive_list::Reader, struct_list::Reader, and others.
- Add support for List(Void) in primitive_list::as_slice().
- Deprecate StructBuilder::get_pointer_field_mut().
- Improve docstring on dynamic_struct::Reader::has().
- Update try_push_segment() to avoid possible overflow panic in 32-bit mode.
- Add overflow checking during segment table reading, to prevent some potential denial of service attacks on 32-bit targets.
- Deprecate SegmentLengthsBuilder::push_segment() in favor of try_push_segment().
- Add read_message_no_alloc() and try_read_message_no_alloc() in serialize and serialize_packed.
- Enable write_message() in no-alloc mode.
- Map std::io::ErrorKind::UnexpectedEof to capnp::ErrorKind::PrematureEndOfFile.
- Make BuilderArena usable in no-alloc contexts. Only single-segment messages are supported.
- Add SingleSegmentAllocator, for use in no-alloc contexts.
- Add #[inline] attribute to many text::Reader and text::Builder methods.
- Add optional (default-enabled)
alloc
feature to allow no-alloc mode. - Lazier UTF-8 validation.
- Add missing #[inline] attributes for f32 and f64.
- Add optional
embedded-io
feature. - Make SliceSegments a special case of BufferSegments.
- Fix indexing bug in
schema::FieldSubset
.
- Fix type mismatch copy/paste bug in
dynamic_list::Builder::set()
.
- Add support for reflection. See dynamic_value.rs and schema.rs.
- Fix "stacked borrow" errors found by miri.
- Remove deprecated
HasTypeId::type_id()
method. - Remove deprecated
MessageSize::plus_eq
method. - Remove
RefCell
from builder arena. Should result in minor performance boost. - Mark
Allocator::deallocate_segment
asunsafe
. - Remove
ToU16
andFromU16
traits in favor ofcore::convert
traits. - Remove
FromStructBuilder
andFromStructReader
traits in favor ofcore::convert
traits.
- Deprecate
HasTypeId::type_id()
in favor ofHasTypeId::TYPE_ID
.
- Remove list pointer munging.
- Add
rust-version
field in Cargo.toml, for better error messages when somone uses and old rustc. - Add
is_empty()
methods. - Deprecate
MessageSize::plus_eq
in favor ofAddAssign
. - Add some
Default
impls. - Lots of linting and formatting changes that should not have an observeable effect.
- Move HasStructSize::struct_size() into a constant HasStructSize::STRUCT_SIZE.
- Move HasTypeId::type_id() into a constant HasTypeId::TYPE_ID.
- Updated minimum supported rustc versino to 1.65.0.
- Use generic associated types in Owned and OwnedStruct.
- Add capability::get_resolved_cap().
- Handle case when
alloc::alloc_zeroed()
returns null.
- Add
try_get()
method for the lists. - Add missing bounds checking in
text_list::Builder
. - Improve documentation.
- Fix potential integer overflows in
set_list_pointer()
andzero_object_helper()
.
- Add serialize::read_message_from_flat_slice_no_alloc().
- Update rpc_try feature to work with try_trait_v2
- Add capnp::serialize::BufferSegments.
- Add capnp::message::TypedBuilder.
- Add as_slice() methods for primitive_list. (These are only enabled for little endian targets.)
- Add list_list::Builder::set().
- Add HeapAllocator::max_segment_words().
- Avoid potential integer overflows that could cause too many segments to be allocated.
- Include LICENSE in published crate.
- Add
sync_reader
feature, which allows multithreaded reading of a shared message. - Change
ReaderOptions.traversal_limit_in_words
from au64
to anOption<usize>
. - Remove unneeded
To
type parameter ofSetPointerBuilder
.
- Add blanket impl Allocator for &mut A where A: Allocator, allowing easier reuse of ScratchSpaceHeapAllocator.
- Fix incorrect calculation in
capnp::serialize::compute_serialized_size_in_words()
.
- Deprecate unsafe functions
data::new_reader()
anddata::new_builder()
.
- Add
impl <S> ReaderSegments for &S where S: ReaderSegments
.
- Fix bug where
read_segment_table()
wrongly handled short reads.
- Add alignment check in
ScratchSpaceHeapAllocator::new()
.
- Add no_std support, via a new "std" feature flag.
- Simplify
message::Allocator
trait andScratchSpaceHeapAllocator
. - Add
serialize.try_read_message()
andserialize_packed::try_read_message()
. - Remove deprecated
ServerHook
trait.
- Fix bug where ScratchSpaceHeapAllocator returned an incorrect buffer length.
- Add capability::FromServer trait.
- Fix buggy Iterator::nth() implementation for ListIter.
- Add "unaligned" feature flag to allow use of unaligned memory.
- Remove
Word::bytes_to_words()
andWord::bytes_to_words_mut()
. - Change a bunch of interfaces to use
u8
instead ofWord
. - Remove
read_message_from_words()
in favor ofread_message_from_flat_slice()
. - Add new
serialize::SegmentLengthsBuilder
API. - Bump minimum required rustc version to 1.40.0.
- Deprecate
read_message_from_words()
in favor ofread_message_from_flat_slice()
. - Remove incorrect doc comments on
bytes_to_words()
. (Misaligned access is never okay.)
- Remove internal capnp::map::Map and use async/await instead.
- Remove the "futures" feature and the optional futures 0.1 dependency, in favor of std::future::Future.
- Bump minimum support rustc version to 1.39.0.
- Add serialize::read_message_from_flat_slice().
- Allow buffer passed to read_message_from_words() to be larger than the actual message.
- Remove dependency on byteorder crate, in favor of from_le_bytes() and to_le_bytes().
- Simplify handling of pointer defaults by adding default parameter to FromPointerReader.
- Add IntoInternalStructReader as a bound on OwnedStruct::Reader.
- Remove capnp_word!() macro in favor of const fn ::capnp::word().
- Remove deprecated items.
- Update to 2018 edition.
- Use dyn keyword for trait objects.
- Update minimum required rustc version to 1.35.
- Implement DerefMut for text::Builder
- Add any_pointer_list and raw::get_struct_pointer_section().
- Add support for pointer field defaults.
- Add optional rpc_try feature, implementing std::ops::Try for Promise.
- Add 'raw' module with get_struct_data_section(), get_list_bytes(), and other functions.
- Avoid potential undefined behavior in canonicalizaion.
- Update a bunch of internal usages of
try!()
to?
.
- Add IntoInternalStructReader trait and struct_list::Builder::set_with_caveats() method.
- Update deprecation attributes, to satisfy clippy.
- Rename a bunch of as_reader() methods to into_reader(), to satisfy clippy.
- Avoid some unnecessary heap allocation that could occur when reading multisegment messages.
- Add message::Builder::set_root_canonical() method. Relies on a new signature for SetPointerBuilder.
- Mark bytes_to_words() and bytes_to_words_mut() as unsafe, due to possible alignment issues. Please refer to #101 for discussion.
- Delete deprecated items.
- Drop support for automatically imbuing message builders with capabilities (was unsafe). You should use capnp_rpc::ImbuedMessageBuilder now if you want that functionality. See the calculator example.
- Bump minimum supported rustc version to 1.26.0.
- Deprecate borrow() in favor of reborrow().
- Add serialize::write_message_segments().
- Fix bug where is_canonical() could sometimes erroneously return true.
- Add message::Builder::into_reader() and message::Reader::into_typed().
- Add message::TypedReader.
- Appease new "tyvar_behind_raw_pointer" lint (see rust-lang/rust#46906).
- Implement capability_list, to support List(Interface).
- Avoid constructing (zero-length) slices from null pointers, as it seems to be a possible source of undefined behavior.
- Add some IntoIterator implementations.
- Avoid some situations where we would construct (but not dereference) out-of-bounds pointers.
- Deprecate Word::from() in favor of capnp_word!().
- Add constant::Reader to support struct and list constants.
- In canonicalization, account the possibility of nonzero padding in primitive lists.
- Do bounds-checking by (ptr, size) pairs rather than (ptr, end_ptr) pairs.
- Fix some canonicalization bugs.
- Implement
as_reader()
for lists. - Implement
canonicalize()
andis_canonical()
. - Fix bug where
total_size()
returned wrong answer on empty struct lists.
- Implement struct list upgrades.
- Fix bug where
message.init_root::<any_pointer::Builder>()
did not clear the old value.
- Eliminate possible void-list-amplification in total_size().
- Eliminate panics in total_size() and set_root().
- Eliminate possible void-list-amplification in zero_object_helper().
- Prevent integer overflow possible with very long struct lists on 32-bit systems.
- Fix bug where the capnp_word!() macro was not exported for big endian targets.
- Shave some bytes off the representation of StructReader and friends.
- Fix some potential integer overflows.
- Redesign segment arenas to require less unsafe code.
- Replace optional GJ dependency with futures-rs.
- Remove
ResultsDoneHook
hack. - No breaking changes for non-RPC users.
- Implement DoubleEndedIter for ListIter.
- Implement Fromstd::str::Utf8Error for ::capnp::Error.
- Address some new linter warnings.
- Fix rare case where
serialize_packed::read()
could fail on valid input.
- Get
message::Builder::get_root_as_reader()
to work on empty messages.
- Implement
From<std::string::FromUtf8Error>
forcapnp::Error
- More and better iterators.