mirror of
https://github.com/clap-rs/clap
synced 2024-12-13 22:32:33 +00:00
fix(derive): Better subcommand type errors for Vec
This commit is contained in:
parent
4f17f998cb
commit
f121a8bdf6
1 changed files with 1 additions and 1 deletions
|
@ -410,7 +410,6 @@ pub fn gen_constructor(fields: &[(&Field, Item)]) -> TokenStream {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
Ty::Vec |
|
|
||||||
Ty::Other => {
|
Ty::Other => {
|
||||||
quote_spanned! { kind.span()=>
|
quote_spanned! { kind.span()=>
|
||||||
#field_name: {
|
#field_name: {
|
||||||
|
@ -418,6 +417,7 @@ pub fn gen_constructor(fields: &[(&Field, Item)]) -> TokenStream {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
Ty::Vec |
|
||||||
Ty::OptionOption |
|
Ty::OptionOption |
|
||||||
Ty::OptionVec => {
|
Ty::OptionVec => {
|
||||||
abort!(
|
abort!(
|
||||||
|
|
Loading…
Reference in a new issue