Skip to content

Derive Serde's Serialize and Deserialize for the generated message structs #178

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

Closed
glennib opened this issue Sep 25, 2022 · 1 comment
Closed

Comments

@glennib
Copy link

glennib commented Sep 25, 2022

I have a use case where I need to serialize messages received on a ROS topic into a binary format.
I figured I could use Serde on the rosrust_msg::* types to achieve this.
It seems like the generated message types don't implement Serialize and Deserialize.
Would it be possible to add those derive macros to the generated message types?
I tried to do it, but I'm not sure where to append the use serde::{Serialize, Deserialize}; line in the rosrust code.
If someone can point me in the right direction I'll make a PR.

@adnanademovic
Copy link
Owner

I've explained in #137 that the new dynamic data format can be used to work with serde.

There were PRs before, you can read the whole discussion in #137 about why none were merged.

@adnanademovic adnanademovic closed this as not planned Won't fix, can't repro, duplicate, stale Sep 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants