From 819049ac91f47ea822ca1e68bc57e4e8b66b0d0a Mon Sep 17 00:00:00 2001 From: ksss Date: Tue, 26 May 2026 15:29:53 +0900 Subject: [PATCH] [DOC] Correct `StringScanner#named_captures` --- ext/strscan/strscan.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/strscan/strscan.c b/ext/strscan/strscan.c index 0d7cd96c8d..6f9516442b 100644 --- a/ext/strscan/strscan.c +++ b/ext/strscan/strscan.c @@ -2220,8 +2220,8 @@ named_captures_iter(const OnigUChar *name, * call-seq: * named_captures -> hash * - * Returns the array of captured match values at indexes (1..) - * if the most recent match attempt succeeded, or nil otherwise; + * Returns a hash of named captures for the most recent regexp match, + * or an empty hash if there are no named captures; * see [Captured Match Values][13]: * * ```rb