use samotop_async_trait::async_trait; #[async_trait] trait Trait { #[future_is[Sync]] async fn method(&mut self); } struct Struct { value: T, } #[async_trait] impl Trait for Struct { #[future_is[Sync]] async fn method(&mut self) { println!("{}", self.value); } } fn main() {}