From 38d44404a589590e0443444f2206d7e9859b09fe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20Pu=C4=8Dil?= Date: Thu, 6 Nov 2025 17:11:21 +0100 Subject: [PATCH] Fix param name in doc comment for std.Io.Reader.peek() The old doc comment mentioned a parameter `len` three times, but the function does not accept such a parameter - it is actually called `n`. --- lib/std/Io/Reader.zig | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/std/Io/Reader.zig b/lib/std/Io/Reader.zig index e2344e959e..167e1cb91f 100644 --- a/lib/std/Io/Reader.zig +++ b/lib/std/Io/Reader.zig @@ -469,15 +469,15 @@ pub fn readVecAll(r: *Reader, data: [][]u8) Error!void { } } -/// Returns the next `len` bytes from the stream, filling the buffer as +/// Returns the next `n` bytes from the stream, filling the buffer as /// necessary. /// /// Invalidates previously returned values from `peek`. /// /// Asserts that the `Reader` was initialized with a buffer capacity at -/// least as big as `len`. +/// least as big as `n`. /// -/// If there are fewer than `len` bytes left in the stream, `error.EndOfStream` +/// If there are fewer than `n` bytes left in the stream, `error.EndOfStream` /// is returned instead. /// /// See also: