Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: export chunks in std/io #3497

Closed
wants to merge 5 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
short-hand
  • Loading branch information
bartlomieju committed Dec 16, 2019
commit c0c576787c685b5162eeb763f00870fd9a9f38d2
4 changes: 1 addition & 3 deletions std/io/bufio.ts
Original file line number Diff line number Diff line change
Expand Up @@ -596,7 +596,5 @@ export async function* chunks(

/** Read from reader until EOF and emit lines */
export async function* lines(reader: Reader): AsyncIterableIterator<string> {
for await (const line of chunks(reader, "\n")) {
yield line;
}
yield* chunks(reader, "\n");
}