diff options
| author | huntc <[email protected]> | 2021-12-10 14:18:22 +1100 |
|---|---|---|
| committer | huntc <[email protected]> | 2021-12-10 14:18:22 +1100 |
| commit | 29fee65616737a632d33c97a74f937949034ac5c (patch) | |
| tree | ac71d845c8776331667a6860c9ddacaf88277d76 | |
| parent | 7256ff3e71ceea9091349b040a2ebc987aca590c (diff) | |
std also required an implementation
| -rw-r--r-- | embassy/src/io/std.rs | 6 |
1 files changed, 6 insertions, 0 deletions
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<T: std_io::AsyncWrite> AsyncWrite for FromStdIo<T> { | |||
| 32 | .poll_write(cx, buf) | 32 | .poll_write(cx, buf) |
| 33 | .map_err(|e| e.into()) | 33 | .map_err(|e| e.into()) |
| 34 | } | 34 | } |
| 35 | fn poll_flush(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Result<()>> { | ||
| 36 | let Self(inner) = unsafe { self.get_unchecked_mut() }; | ||
| 37 | unsafe { Pin::new_unchecked(inner) } | ||
| 38 | .poll_flush(cx) | ||
| 39 | .map_err(|e| e.into()) | ||
| 40 | } | ||
| 35 | } | 41 | } |
