-
Notifications
You must be signed in to change notification settings - Fork 9
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
Failing to round-trip deserialize with Bincoded formula #18
Comments
Also it seems adding a dummy field to the end of the formula works around the issue. |
Thank you for the report. I will investigate it next week |
Sorry for late reply.
Code ensures to satisfy first one by truncating the buffer. |
For more straightforward usage consider using |
I'm adding assert to the |
It looks like if I have a member that contains Bincoded, either deserialization fails or I'm doing something wrong. For some reason the byte array ends up pointing to the whole input buffer being deserialized instead of correctly round-tripping.
Left is the buffer we actually retrieved from deserialized, right is the expected deserialized buffer and "full serialized" is the input buffer provided to
alkahest::deserialize
. It's interesting that the buffer returned ends at the right spot & just has the wrong starting point.Here's the example code snippet: https://gist.github.com/vlovich/9e2645ed83e546777422766e825cb463
Cargo.toml:
Everything seems OK if I avoid Bincoded (https://gist.github.com/vlovich/2b352bcfe26ad5d40958561f166d0aa7).
The text was updated successfully, but these errors were encountered: