Crates.io | enum_to_vec |
lib.rs | enum_to_vec |
version | 0.1.0 |
source | src |
created_at | 2024-11-17 02:44:07.168926 |
updated_at | 2024-11-17 02:44:07.168926 |
description | Enum to vec |
homepage | https://github.com/ptechen |
repository | https://github.com/ptechen/enum_to_vec.git |
max_upload_size | |
id | 1450857 |
size | 6,187 |
use enum_to_vec::ToVec;
#[derive(ToVec)]
#[snake_case]
enum Test {
Test,
TestA,
TestB,
}
#[test]
fn test_vec() {
assert_eq!(vec!["test", "test_a", "test_b"], Test::to_vec());
}