From fe7f37e9b3cd7fbfdf555abfd21c4727dedc6685 Mon Sep 17 00:00:00 2001 From: Maximiliano Sandoval Date: Wed, 7 Aug 2024 09:43:50 +0200 Subject: [PATCH] property_string: clippy: define bound once Fixes the clippy lint: warning: bound is defined in more than one place --> proxmox-schema/src/property_string.rs:352:14 | 352 | pub fn parse(value: &str) -> Result | ^ 353 | where 354 | T: for<'de> Deserialize<'de>, | ^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#multiple_bound_locations = note: `#[warn(clippy::multiple_bound_locations)]` on by default Signed-off-by: Maximiliano Sandoval Reviewed-by: Lukas Wagner --- proxmox-schema/src/property_string.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/proxmox-schema/src/property_string.rs b/proxmox-schema/src/property_string.rs index 7dd60f76..7b5a4ed1 100644 --- a/proxmox-schema/src/property_string.rs +++ b/proxmox-schema/src/property_string.rs @@ -349,9 +349,9 @@ pub fn print(value: &T) -> Result { } /// Deserialize a value from a property string. -pub fn parse(value: &str) -> Result +pub fn parse(value: &str) -> Result where - T: for<'de> Deserialize<'de>, + T: for<'de> Deserialize<'de> + ApiType, { parse_with_schema(value, &T::API_SCHEMA) }