mirror of
https://github.com/astral-sh/ruff.git
synced 2025-09-30 05:45:24 +00:00
Upgrade to Rust 1.82 (#13816)
This commit is contained in:
parent
bd33b4972d
commit
2ff36530c3
11 changed files with 58 additions and 50 deletions
|
@ -75,12 +75,11 @@ pub(crate) fn derive_cache_key(item: &DeriveInput) -> syn::Result<TokenStream> {
|
|||
}
|
||||
}
|
||||
|
||||
let field_attr = match &field.ident {
|
||||
Some(ident) => quote!(self.#ident),
|
||||
None => {
|
||||
let index = syn::Index::from(i);
|
||||
quote!(self.#index)
|
||||
}
|
||||
let field_attr = if let Some(ident) = &field.ident {
|
||||
quote!(self.#ident)
|
||||
} else {
|
||||
let index = syn::Index::from(i);
|
||||
quote!(self.#index)
|
||||
};
|
||||
|
||||
fields.push(quote!(#field_attr.cache_key(key);));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue