borsh-rs
borsh-rs copied to clipboard
Rust implementation of Binary Object Representation Serializer for Hashing
Should be done in the modules of this [tests.rs section](https://github.com/near/borsh-rs/blob/master/borsh/tests/tests.rs#L74-L103). [Example test](https://github.com/near/borsh-rs/blob/master/borsh/tests/schema/test_simple_enums.rs#L24-L32) Example [commit](https://github.com/near/near-sdk-rs/pull/1212/commits/bd45f91862d51816c3b1459431383d98e8086304) with replacement.
for roundtrips being possible `Cow
I understand the issue with deserializing a `Vec`, (#52 and #19), but if I'm not mistaken, there is no such attack on the serialization side. It seems unnecessary to do...
sketch of possible solution to #92, both the original issue and the widened perspective this results in ```rust #[derive(borsh::BorshSchema)] enum A { Bacon(Vec), Eggs, } ``` => ```bash { "Vec":...
Hi there, We have some existing serialized data of something like ``` use borsh::{BorshDeserialize, BorshSerialize}; #[derive(BorshSerialize, BorshDeserialize)] struct MyStruct { field1: u32, field2: String, } ``` We would now like...
We use enum discriminator as version of state. So at some point our enum will have `enum State { A(FooBar) = 444, B(FizzBazz) = 445, }`. Another use case for...
this might be proposed as eventual changeset in #312, is easy to manipulate with respect to resolving conflicts, fixing ci, etc
## 🤖 New release * `borsh`: 1.5.1 -> 1.6.0 (✓ API compatible changes) * `borsh-derive`: 1.5.1 -> 1.6.0 Changelog ## `borsh` ## [1.6.0](https://github.com/near/borsh-rs/compare/borsh-v1.5.1...borsh-v1.6.0) - 2024-10-08 ### Added - ser/de for...
Implement `BorshSerialize` and `BorshDeserialize` for `serde_json::Value`. This is useful, for example, if a program is to take an arbitrary JSON as input (as `Value`), and store it as raw bytes....