-
Notifications
You must be signed in to change notification settings - Fork 27
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support enum variants that have aliases (#53)
* Support enum variants that have aliases * Return error instead of panic on enum with 0 variants Before PR 53: thread 'main' panicked at /git/tmp/serde-reflection/serde-reflection/src/de.rs:431:18: variant indexes must be a non-empty range 0..variants.len() First draft of PR 53, debug mode (overflow checks): thread 'main' panicked at /git/tmp/serde-reflection/serde-reflection/src/de.rs:435:42: attempt to subtract with overflow First draft of PR 53, release mode: Failed to deserialize value: "invalid value: integer `0`, expected variant index 0 <= i < 0" This commit: Not supported: deserialize_enum with 0 variants
- Loading branch information
Showing
5 changed files
with
207 additions
and
56 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.