You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With a struct like the one in the following snippet:
structFoo{field:Box<str>,}
It is not possible to automatically derive SerializeValue and DeserializeValue but I do not see any reason way that is the case.
To me, after a very fast read of the relevant source code (Serialize, Deserialize), it seems like there is just a small code addition to support this use case.
If there is the need I would be open to implement this small change myself and open a PR. I think it would be really useful for my use case.
Thanks!
The text was updated successfully, but these errors were encountered:
This turns out to be a bit more tricky. To sum up my comment:
SerializeValue should be implemented for str instead of &str.
SerializeValue should be implemented for Arc<T>
DeserializeValue should be implemented for Box<T> and Arc<T> - we need to verify that it allows using Box<str>
The above is tightly coupled with solving Issue with type renaming in ser/deser errors. #1343
With a struct like the one in the following snippet:
It is not possible to automatically derive
SerializeValue
andDeserializeValue
but I do not see any reason way that is the case.To me, after a very fast read of the relevant source code (Serialize, Deserialize), it seems like there is just a small code addition to support this use case.
If there is the need I would be open to implement this small change myself and open a PR. I think it would be really useful for my use case.
Thanks!
The text was updated successfully, but these errors were encountered: