From 29fee65616737a632d33c97a74f937949034ac5c Mon Sep 17 00:00:00 2001 From: huntc Date: Fri, 10 Dec 2021 14:18:22 +1100 Subject: [PATCH] std also required an implementation --- embassy/src/io/std.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/embassy/src/io/std.rs b/embassy/src/io/std.rs index ddec8d56d..580d52891 100644 --- a/embassy/src/io/std.rs +++ b/embassy/src/io/std.rs @@ -32,4 +32,10 @@ impl AsyncWrite for FromStdIo { .poll_write(cx, buf) .map_err(|e| e.into()) } + fn poll_flush(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll> { + let Self(inner) = unsafe { self.get_unchecked_mut() }; + unsafe { Pin::new_unchecked(inner) } + .poll_flush(cx) + .map_err(|e| e.into()) + } }