Skip to content

StreamExt::find method analogous to Iterator::find? #2705

Open
@nullchinchilla

Description

@nullchinchilla

https://doc.rust-lang.org/std/iter/trait.Iterator.html#method.find

This is something I've always wanted in Stream-based code. Right now I have to use manual while-loop iteration for anything involving "read from this stream until something you need is found, then stop". The "stop" part also makes it impossible to express with fold and the like.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions