pub async fn write_frame<W, T>(writer: &mut W, msg: &T) -> Result<()>where W: AsyncWriteExt + Unpin, T: Serialize,
Back-compat wrapper for callers still on std::io::Result.
std::io::Result