nest_struct 0.5.5

Nest struct and enum definitions with minimal syntax changes
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#![allow(dead_code)]
#[macro_use]
extern crate nest_struct;
struct CustomNameLast<'a> {
    first: &'a str,
    last: &'a str,
}
enum CustomName<'a> {
    First,
    Last(CustomNameLast<'a>),
}
enum DeepNested<'a, AGE> {
    Named { a: u32, b: u32 },
    Unnamed(u32, u32),
    None,
    NestedEnum(CustomName<'a>, u32),
    id(CustomName<'a>),
}