mirror of
https://github.com/Lokathor/bytemuck.git
synced 2024-11-21 22:32:23 +00:00
a637e1d983
* Add support for deriving Zeroable for fieldful enums if: 1. the enum is repr(Int), repr(C), or repr(C, Int), 2. the enum has a variant with discriminant 0, 3. and all fields of the variant with discriminant 0 are Zeroable. * Allow using derive(Zeroable) with explicit bounds. Update documentation and doctests. * doc update * doc update * remove unused * Factor out get_zero_variant helper function. * Use i128 to track disciminants instead of i64. * Add doc-comment for `get_fields` Co-authored-by: Daniel Henry-Mantilla <daniel.henry.mantilla@gmail.com> * Update derive/src/traits.rs Co-authored-by: Daniel Henry-Mantilla <daniel.henry.mantilla@gmail.com> --------- Co-authored-by: Daniel Henry-Mantilla <daniel.henry.mantilla@gmail.com> |
||
---|---|---|
.. | ||
basic.rs |