From 4d19f248b01cc1f7ac898ad6a32e410df0142ecb Mon Sep 17 00:00:00 2001 From: cyqsimon <28627918+cyqsimon@users.noreply.github.com> Date: Sun, 19 Oct 2025 21:02:42 +0800 Subject: [PATCH] Improve function docs for `Repository::tag_foreach` --- src/repo.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/repo.rs b/src/repo.rs index ed24e67529..07d3a7c55f 100644 --- a/src/repo.rs +++ b/src/repo.rs @@ -2043,8 +2043,10 @@ impl Repository { } } - /// iterate over all tags calling `cb` on each. - /// the callback is provided the tag id and name + /// Iterate over all tags, calling the callback `cb` on each. + /// The arguments of `cb` are the tag id and name, in this order. + /// + /// Returning `false` from `cb` causes the iteration to break early. pub fn tag_foreach(&self, cb: T) -> Result<(), Error> where T: FnMut(Oid, &[u8]) -> bool,