From 144316854c44d51f7e1ae6ffdd9550f265940613 Mon Sep 17 00:00:00 2001 From: Tait Hoyem Date: Wed, 3 Jul 2024 11:37:49 -0600 Subject: [PATCH] Change trait bound to be more generic Change trait bounds for auto-impl of MessageConversion --- atspi-common/src/events/mod.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/atspi-common/src/events/mod.rs b/atspi-common/src/events/mod.rs index d0fea325..b197df7d 100644 --- a/atspi-common/src/events/mod.rs +++ b/atspi-common/src/events/mod.rs @@ -421,7 +421,10 @@ impl MessageConversion for LegacyAddAccessibleEvent { #[cfg(feature = "zbus")] impl MessageConversion for T where - T: From, + ObjectRef: Into, + // this bound is not actually used for anything, but I do not want to implement this trait for + // just any type that has an infallible conversion from an ObjectRef + T: BusProperties, { type Body = EventBodyOwned; fn try_from_message_unchecked(msg: &zbus::Message) -> Result {