diff --git a/rustbus_derive/Cargo.toml b/rustbus_derive/Cargo.toml index 951b20c..de5e5f3 100644 --- a/rustbus_derive/Cargo.toml +++ b/rustbus_derive/Cargo.toml @@ -13,7 +13,7 @@ homepage = "https://github.com/KillingSpark/rustbus" proc-macro = true [dependencies] -syn = "1.0" +syn = "2.0" quote = "1.0" proc-macro2 = "1.0" diff --git a/rustbus_derive/src/structs.rs b/rustbus_derive/src/structs.rs index 1d57fb7..813a84e 100644 --- a/rustbus_derive/src/structs.rs +++ b/rustbus_derive/src/structs.rs @@ -25,7 +25,7 @@ pub fn make_struct_unmarshal_impl( ) -> TokenStream { let marshal = struct_field_unmarshal(fields); - let mut bufdef = syn::LifetimeDef { + let mut bufdef = syn::LifetimeParam { attrs: Vec::new(), lifetime: syn::Lifetime::new("'__internal_buf", proc_macro2::Span::call_site()), colon_token: None, diff --git a/rustbus_derive/src/variants.rs b/rustbus_derive/src/variants.rs index 0a844ae..5c263d8 100644 --- a/rustbus_derive/src/variants.rs +++ b/rustbus_derive/src/variants.rs @@ -160,7 +160,7 @@ pub fn make_variant_unmarshal_impl( tokens }); - let mut bufdef = syn::LifetimeDef { + let mut bufdef = syn::LifetimeParam { attrs: Vec::new(), lifetime: syn::Lifetime::new("'__internal_buf", proc_macro2::Span::call_site()), colon_token: None,