-
Notifications
You must be signed in to change notification settings - Fork 123
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
Conversion between Value
and any T: Serialize/Deserialize
#140
Comments
There already is a `Deserializer` implementation for `Value`, so this
shouldn't be very hard to implement.
…On Thu, Dec 13, 2018, 02:01 Diggory Blake ***@***.*** wrote:
Take a look at serde_json::from_value and serde_json::to_value - these
functions would exactly mirror that.
RON has the unique opportunity to be an "impartial" serialization format
for storing structured data internally in rust programs, so that it can
still be converted to other formats without having to know the original
type, but to do that, you need a way to go from arbitrary rust types to a
RON value, and vice versa.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#140>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AWFFucD4Q7BwKgvEamLaYqTgb3mRo25wks5u4acDgaJpZM4ZQu4l>
.
|
Yes, please add a (And |
Switch from ron serde_yaml because of ron-rs/ron#140
Issue has had no activity in the last 180 days and is going to be closed in 7 days if no further activity occurs |
activity |
Please please can we have this? I am using partial serialization/deserialization for automatic upgrading of file types and I really want support for a better format as JSON. The TOML crate doesn't support enums and tuples, so I arrived here. Having the functions like suggested by @Diggsey would make that use case oh so much more painless. |
I think serializing into the |
can we add our own glue code to have (looked at code again, current serializer outputs to |
Take a look at
serde_json::from_value
andserde_json::to_value
- these functions would exactly mirror that.RON has the unique opportunity to be an "impartial" serialization format for storing structured data internally in rust programs, so that it can still be converted to other formats without having to know the original type, but to do that, you need a way to go from arbitrary rust types to a RON value, and vice versa.
The text was updated successfully, but these errors were encountered: