assert-order 0.0.3

Assert the order of Rust enum variants.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# `assert-order`
A Rust crate for asserting the definition order of enum Variants.

## Motivation
For serialization formats that aren't self-describing, the typical
way for discriminating enum variants is to use an integer
discriminant. Unfortunately, this means that reordering variants
will cause deserialization of previously serialized data to fail
(potentially silently).

In general, you _can_ just document strict ordering and ensure that
changes aren't made to the variant ordering. However, it is more
comforting to have this documented requirement as an assertion in a
test.

## License
Licensed under the MIT license.