Skip to content

Add set_limit() fn to std::io::Take #27269

Closed
@carllerche

Description

@carllerche

std::io::Cursor has a fn to update the position yet Take does not have a fn for setting the limit. Being able to update the limit is required for implementing various traits for Take. For example, Read works by updating the limit.

I was hoping to implement Buf for Take (in the bytes crate) but am currently unable to do so.

Metadata

Metadata

Assignees

No one assigned

    Labels

    T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions