refactor: fix fmt and clippy based on contributions
This commit is contained in:
parent
6f434c84cd
commit
0578b73c8a
@ -1087,7 +1087,7 @@ fn de_attribute_sequence() {
|
|||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn de_nested_macro_rules() {
|
fn de_nested_macro_rules() {
|
||||||
init!();
|
init();
|
||||||
|
|
||||||
macro_rules! float_attrs {
|
macro_rules! float_attrs {
|
||||||
($type:ty) => {
|
($type:ty) => {
|
||||||
|
|||||||
@ -253,12 +253,12 @@ impl From<&syn::PathSegment> for Field {
|
|||||||
match args.args.first() {
|
match args.args.first() {
|
||||||
Some(syn::GenericArgument::Type(Path(ref path))) => {
|
Some(syn::GenericArgument::Type(Path(ref path))) => {
|
||||||
return Field::from(&path.path);
|
return Field::from(&path.path);
|
||||||
},
|
}
|
||||||
Some(syn::GenericArgument::Type(syn::Type::Group(syn::TypeGroup { elem, .. }))) => {
|
Some(syn::GenericArgument::Type(syn::Type::Group(syn::TypeGroup { elem, .. }))) => {
|
||||||
if let syn::Type::Path(ref group) = elem.as_ref() {
|
if let syn::Type::Path(ref group) = elem.as_ref() {
|
||||||
return Field::from(&group.path);
|
return Field::from(&group.path);
|
||||||
}
|
}
|
||||||
},
|
}
|
||||||
_ => unimplemented!("unable to match '{:?}'", args.args.first()),
|
_ => unimplemented!("unable to match '{:?}'", args.args.first()),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user