TimelyDataflow / abomonation

A mortifying serialization library for Rust
MIT License
322 stars 30 forks source link

[Based on #26] Support reference types (and a pinch of DSTs) #28

Open HadrienG2 opened 5 years ago

HadrienG2 commented 5 years ago

This PR implements Abomonation for most references types, and a few DSTs along the way. It is what I had in mind while opening #27 . The main advantage of implementing Abomonation for these types is that it becomes much easier to serialize types containing Rust references (which are, after all, almost like every other pointer).

This PR raises a few questions that we may want to discuss here:

For convenience reasons, this PR is based on #22, #24, #25 and #26. Reviewing these PRs first is recommended, but if you want to review this one in isolation, please consider doing so commit-by-commit in order to get a clean diff.

Fixes #27 .

HadrienG2 commented 5 years ago

I have pushed a draft of the Abomonation<'bytes> memory safety fix that we discussed in #27 , but it has a bunch of FIXMEs that I hope to improve upon before merging.

HadrienG2 commented 5 years ago

Alright, I think this one is now ready to go (though by virtue of being on the top of the PR stack, it will probably go in last).