Fix rustc 1.32.0 build

This commit is contained in:
Graham Esau 2019-12-08 22:34:48 +00:00
parent 4c4fb1cf36
commit 9579d6a94c

View file

@ -411,13 +411,15 @@ fn get_with_from_attr(attr: &syn::Attribute) -> Option<syn::LitStr> {
_ => return None,
};
for nm in nested_metas {
match nm {
NestedMeta::Meta(Meta::NameValue(MetaNameValue {
if let NestedMeta::Meta(Meta::NameValue(MetaNameValue {
path,
lit: Lit::Str(with),
..
})) if path.is_ident("with") => return Some(with),
_ => {}
})) = nm
{
if path.is_ident("with") {
return Some(with);
}
}
}
None