From ba73a7aeb3dd431f0acdf279437bc151a88ec8aa Mon Sep 17 00:00:00 2001 From: boyned//Kampfkarren <3190756+Kampfkarren@users.noreply.github.com> Date: Sat, 4 Jan 2025 19:15:44 -0500 Subject: [PATCH 1/2] Remove unnecessary lifetime for field names --- pbjson-build/src/generator/message.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pbjson-build/src/generator/message.rs b/pbjson-build/src/generator/message.rs index 2822f56..22e0f7d 100644 --- a/pbjson-build/src/generator/message.rs +++ b/pbjson-build/src/generator/message.rs @@ -706,7 +706,7 @@ fn write_deserialize_field_name( {indent} {{ {indent} struct GeneratedVisitor; -{indent} impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {{ +{indent} impl serde::de::Visitor<'_> for GeneratedVisitor {{ {indent} type Value = GeneratedField; {indent} fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {{ From 5440322132f28ca95e718e80966f573d870583e2 Mon Sep 17 00:00:00 2001 From: boyned//Kampfkarren <3190756+Kampfkarren@users.noreply.github.com> Date: Sat, 4 Jan 2025 19:16:47 -0500 Subject: [PATCH 2/2] Remove lifetime for enums --- pbjson-build/src/generator/enumeration.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pbjson-build/src/generator/enumeration.rs b/pbjson-build/src/generator/enumeration.rs index c833484..a511d8c 100644 --- a/pbjson-build/src/generator/enumeration.rs +++ b/pbjson-build/src/generator/enumeration.rs @@ -98,7 +98,7 @@ fn write_visitor( writer, r#"{indent}struct GeneratedVisitor; -{indent}impl<'de> serde::de::Visitor<'de> for GeneratedVisitor {{ +{indent}impl serde::de::Visitor<'_> for GeneratedVisitor {{ {indent} type Value = {rust_type}; {indent} fn expecting(&self, formatter: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {{