Make flush do nothing by default

This commit is contained in:
boommy 2026-03-03 17:13:53 +04:00
parent 791d1906a5
commit 7b93fde43d

View file

@ -70,9 +70,9 @@ pub(crate) trait Sink: Send {
async fn wait_writable(&mut self) -> io::Result<()>;
/// Flush all intermediately buffered contents.
/// By default, just waits for the writable state.
/// By default, does nothing.
async fn flush(&mut self) -> io::Result<()> {
self.wait_writable().await
Ok(())
}
}