# std.Io.Reader: rework peekDelimiterInclusive · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/6a25bfc4751ab959f32390963d902bec731129d8)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: 6a25bfc4751ab959f32390963d902bec731129d8

Requested commit: 6a25bfc4751ab959f32390963d902bec731129d8

Commit: 6a25bfc4751ab959f32390963d902bec731129d8

Tree: 8c571a4bb06990b52699e208fd55d3b62ae7a1ad

Author: Andrew Kelley

Committer: Andrew Kelley

## Message

```
std.Io.Reader: rework peekDelimiterInclusive

Now it's based on calling fillMore rather than an illegal aliased stream
into the Reader buffer.

This commit also includes a disambiguation block inspired by #25162. If
`StreamTooLong` was added to `RebaseError` then this logic could be
replaced by removing the exit condition from the while loop. That error
code would represent when `buffer` capacity is too small for an
operation, replacing the current use of asserts.

```

## Parents

- [52730f3f2191aa242b030b9c5f3ca33a7f4fea88](https://git.cafe/gitcafe/zig/commit/52730f3f2191aa242b030b9c5f3ca33a7f4fea88?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/6a25bfc4751ab959f32390963d902bec731129d8?format=markdown)
