mirror of
https://github.com/servo/servo.git
synced 2025-08-07 06:25:32 +01:00
Upgrade remaining components to edition 2018
This commit is contained in:
parent
fd79367491
commit
9c2cc05a8e
48 changed files with 102 additions and 160 deletions
|
@ -3,8 +3,12 @@
|
|||
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use crate::to_css::CssVariantAttrs;
|
||||
use darling::FromField;
|
||||
use darling::FromVariant;
|
||||
use derive_common::cg;
|
||||
use proc_macro2::TokenStream;
|
||||
use quote::quote;
|
||||
use syn::parse_quote;
|
||||
use syn::{self, DeriveInput, Path};
|
||||
use synstructure::{Structure, VariantInfo};
|
||||
|
||||
|
@ -54,7 +58,7 @@ fn parse_non_keyword_variant(
|
|||
}
|
||||
} else {
|
||||
quote! {
|
||||
if let Ok(v) = input.try(|i| <#ty as crate::parser::Parse>::parse(context, i)) {
|
||||
if let Ok(v) = input.r#try(|i| <#ty as crate::parser::Parse>::parse(context, i)) {
|
||||
return Ok(#name::#variant_name(v));
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue