enum_variant_macros 0.3.0

Macros to generate From & TryFrom for enums
Documentation
1
2
3
4
5
6
7
8
9
use enum_variant_macros::*;
#[derive(FromVariants)]
enum Variants {
	Int(i32),
	Float(f32),
	None,
}
fn main() {
}