Skip to content

io: read_to_end and write_all, or more generally Async{Read,Write}Ext #16

Description

@pchickey

When I'm using tokio the two methods I use most frequently, and are missing from wstd, are:

https://docs.rs/tokio/latest/tokio/io/trait.AsyncReadExt.html#method.read_to_end https://docs.rs/tokio/latest/tokio/io/trait.AsyncWriteExt.html#method.write_all

We need at very least to provide implementations of those in wstd.

Maybe we should provide a complete copy of the AsyncReadExt and AsyncWriteExt traits, since there are many other bits in there which people use.

@yoshuawuyts says:

compat with tokio would be great. If you want we can probably build in some
compat methods similar to https://docs.rs/async-compat/latest/async_compat/.
Maybe even behind a flag?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions