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

Implement deserialization of dictionaries using primitives as keys #44

Merged
merged 2 commits into from
Aug 12, 2024

Conversation

Sprixitite
Copy link
Contributor

Previously only worked with strings and would fail quietly if anything else was used (at least on net8.0, haven't checked other targets)

@coveralls
Copy link

coveralls commented Aug 11, 2024

Coverage Status

coverage: 91.979% (+0.03%) from 91.945%
when pulling db9998b on Sprixitite:master
into a572b42 on SamboyCoding:master.

@Sprixitite
Copy link
Contributor Author

Sprixitite commented Aug 11, 2024

With regards to deserializing generic dictionaries (as there currently is a naive serializer for them), it'll probably be necessary to expose an interface to convert objects -> keys and back

Another approach would be to serialize the keys and use the resulting string as the key? Would like to hear some thoughts on this

@SamboyCoding
Copy link
Owner

Content looks good but I would like to have a test to ensure it's valid and doesn't break in future.

@Sprixitite
Copy link
Contributor Author

Sprixitite commented Aug 12, 2024

Good call on adding the tests, I evidently didn't check the floating point stuff well enough, some issues with the decimal point

I've removed double/float support from this PR as a result

@SamboyCoding SamboyCoding merged commit 4393f63 into SamboyCoding:master Aug 12, 2024
2 checks passed
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

Successfully merging this pull request may close these issues.

3 participants