-
-
Notifications
You must be signed in to change notification settings - Fork 16.3k
[libs] Add Read::take_while #70920
Copy link
Copy link
Open
Labels
C-feature-requestCategory: A feature request, i.e: not implemented / a PR.Category: A feature request, i.e: not implemented / a PR.T-libsRelevant to the library team, which will review and decide on the PR/issue.Relevant to the library team, which will review and decide on the PR/issue.
Description
Activity
Metadata
Metadata
Assignees
Labels
C-feature-requestCategory: A feature request, i.e: not implemented / a PR.Category: A feature request, i.e: not implemented / a PR.T-libsRelevant to the library team, which will review and decide on the PR/issue.Relevant to the library team, which will review and decide on the PR/issue.
In #70772 I proposed adding
BufRead::read_while. But as @HeroicKatora pointed out in #70772 (comment)Read::take_whilewould achieve many of the same benefits with fewer downsides. This would act as a counterpart toRead::take, similar toIterator::take_while.Examples