From 05c0e26db0639fd3ae252ea848743a1531bf503c Mon Sep 17 00:00:00 2001 From: Michal Nazarewicz Date: Sat, 2 Dec 2023 22:03:07 +0100 Subject: [PATCH] Tiny documentation fix MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Argument of truncate is called ‘new_len’ not ‘len’ which is what documentation comment uses; fix that. --- src/vec/api.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vec/api.rs b/src/vec/api.rs index 09d2d65d..0a70d4a4 100644 --- a/src/vec/api.rs +++ b/src/vec/api.rs @@ -321,8 +321,8 @@ where /// Shortens the bit-vector, keeping the first `new_len` bits and discarding /// the rest. /// - /// If `len` is greater than the bit-vector’s current length, this has no - /// effect. + /// If `new_len` is greater than the bit-vector’s current length, this + /// has no effect. /// /// The [`.drain()`] method can emulate `.truncate()`, except that it yields /// the excess bits rather than discarding them.