macro_rules! cmdline_struct {
(
$(#[$struct_attr: meta])*
$vis:vis struct $struct_name: ident $(< $lt: lifetime >)? {
$(
$(#[$($field_attrs: tt)*])*
$f_vis:vis $field_name: ident: $field_type: ty
),* $(,)?
}
) => { ... };
(
@build_struct $vis:vis [$($name_ident: tt)*] { } => [$($attribs: tt)*] => [$($built: tt)*]
) => { ... };
(
@build_struct $vis:vis [$($name_ident: tt)*] {
#[default = $default: expr]
$($rest:tt)*
} => [$($attribs: tt)*] => [$($built: tt)*]
) => { ... };
(
@build_struct $vis:vis [$($name_ident: tt)*] {
#[$($field_attrs: tt)*]
$($rest:tt)*
} => [$($attribs: tt)*] => [$($built: tt)*]
) => { ... };
(
@build_struct $vis:vis [$($name_ident: tt)*] {
$f_vis:vis $field_name: ident: $field_type: ty,
$($rest:tt)*
} => [$($attribs: tt)*] => [$($built: tt)*]
) => { ... };
(
@build_parser [$($name_ident: tt)*] {
$(
$(#[$($field_attrs: tt)*])*
$field_name: ident: $field_type: ty,
)*
}
) => { ... };
(
@build_parser_attr
#[default = $expr: expr]
$field_name: ident: $field_type: ty
) => { ... };
(
@build_parser_attr
#[$($field_attrs: tt)*]
$field_name: ident: $field_type: ty
) => { ... };
}