Upgrade to the Rust 2024 edition (#2367)

* Update to rust 2024 edition

* Fixes

* Clean up imports

* Cargo fmt again

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
This commit is contained in:
Dennis Kobert
2025-03-12 17:29:12 -07:00
committed by GitHub
co-authored by Keavon Chambers
parent 927d7dd9b2
commit beb1c6ae64
253 changed files with 980 additions and 1371 deletions
+2 -2
View File
@@ -5,7 +5,7 @@ extern crate proc_macro;
use proc_macro::TokenStream;
use proc_macro2::Span;
use quote::quote;
use syn::{parse_macro_input, DeriveInput, GenericParam, Lifetime, LifetimeParam, TypeParamBound};
use syn::{DeriveInput, GenericParam, Lifetime, LifetimeParam, TypeParamBound, parse_macro_input};
/// Derives an implementation for the [`DynAny`] trait.
///
@@ -62,7 +62,7 @@ fn replace_lifetimes(generics: &syn::Generics, replacement: &str) -> Vec<proc_ma
GenericParam::Type(t) => {
let mut t = t.clone();
t.bounds.iter_mut().for_each(|bond| {
if let TypeParamBound::Lifetime(ref mut t) = bond {
if let TypeParamBound::Lifetime(t) = bond {
*t = Lifetime::new(replacement, Span::call_site())
}
});