Serialization support
jonhoo opened this issue · comments
We should add support for serde::{Serialize, Deserialize}
. The serde docs on custom implementations may be helpful, and the hashbrown
implementation almost certainly will be.
I am very new to Rust. But I would like to help.
@holocenian Did you end up picking this up? :)
@jonhoo Your idea is to implement serialization/deserialization for all four data structures exposed by the crate?
Yeah, that seems reasonable for Serialize
. I'd just stick the main impl on the Ref
types, and then have the non-Ref
impls just call self.pin().serialize
. Deserialize
I think should only be on HashMap
and HashSet
.
Makes sense. I'll work on that.
Should we make serialization support option (via a feature)?
Yes, my inclination would be to make it optional and off by default.
Fixed in #79 🎉