Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

migrate from rustc_serialize to serde #39

Closed
ajdlinux opened this issue Dec 2, 2016 · 1 comment
Closed

migrate from rustc_serialize to serde #39

ajdlinux opened this issue Dec 2, 2016 · 1 comment
Assignees
Milestone

Comments

@ajdlinux
Copy link
Collaborator

ajdlinux commented Dec 2, 2016

rustc_serialize, for various reasons, is semi-deprecated. serde is the anointed successor.

serde is significantly more flexible than rustc_serialize and allows us to do a few things that make our (de)serialisation code just a little bit neater.

The only reason to avoid serde right now is that its derivation features depend on "Macros 1.1", which is currently only in nightly (see rust-lang/rust#35900 - it looks like it will be stabilised sometime quite soon). There is a workaround for stable compilers but it's quite messy. Hopefully, it should work fine with Rust 1.15 (the RFC won't be accepted in time for 1.14).

The only thing we still need rustc_serialize for is docopt, which doesn't support serde yet - this is being tracked at docopt/docopt.rs#128.

See https://github.com/ajdlinux/snowpatch/tree/serde for my progress on this.

@ajdlinux ajdlinux self-assigned this Dec 2, 2016
@ajdlinux ajdlinux added this to the v0.3 milestone Dec 2, 2016
@ruscur
Copy link
Owner

ruscur commented Dec 4, 2016

looks really good

the day 1.15 comes out we merge this

ajdlinux added a commit to ajdlinux/snowpatch that referenced this issue Mar 1, 2017
serde is Rust's next-generation serialisation framework that will
eventually supersede rustc_serialize.

Convert our JSON and TOML serialisation to use serde. We still depend on
rustc_serialize because docopt currently requires it.

Closes: ruscur#39 ("migrate from rustc_serialize to serde")
Signed-off-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
ajdlinux added a commit to ajdlinux/snowpatch that referenced this issue Mar 1, 2017
serde is Rust's next-generation serialisation framework that will
eventually supersede rustc_serialize.

Convert our JSON and TOML serialisation to use serde. We still depend on
rustc_serialize because docopt currently requires it.

Closes: ruscur#39 ("migrate from rustc_serialize to serde")
Signed-off-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants