aboutsummaryrefslogtreecommitdiff
path: root/src/sync
diff options
context:
space:
mode:
authorDmitri Shuralyov <dmitshur@golang.org>2024-06-29 20:35:40 +0000
committerGopher Robot <gobot@golang.org>2024-07-01 13:44:22 +0000
commitcdbf5f2f7e968993560730479d4670c2d6eecd8b (patch)
treeea3f7911976d29ac8810473392328d12d7eef4cc /src/sync
parentc33144c47cbee5506df404553c3769867972f889 (diff)
downloadgo-cdbf5f2f7e968993560730479d4670c2d6eecd8b.tar.xz
sync: refer to Locker interface methods in RWMutex.RLocker doc
The methods being implemented are part of the Locker interface, not the RWMutex struct. Fixes #68250. Change-Id: I609c4d5c44e90a12914a8678971ba295519cc265 Reviewed-on: https://go-review.googlesource.com/c/go/+/595875 Auto-Submit: Dmitri Shuralyov <dmitshur@golang.org> Reviewed-by: Ian Lance Taylor <iant@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Than McIntosh <thanm@google.com>
Diffstat (limited to 'src/sync')
-rw-r--r--src/sync/rwmutex.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/sync/rwmutex.go b/src/sync/rwmutex.go
index 66cb93c44e..1d5b8fde4a 100644
--- a/src/sync/rwmutex.go
+++ b/src/sync/rwmutex.go
@@ -234,7 +234,7 @@ func syscall_hasWaitingReaders(rw *RWMutex) bool {
}
// RLocker returns a [Locker] interface that implements
-// the [RWMutex.Lock] and [RWMutex.Unlock] methods by calling rw.RLock and rw.RUnlock.
+// the [Locker.Lock] and [Locker.Unlock] methods by calling rw.RLock and rw.RUnlock.
func (rw *RWMutex) RLocker() Locker {
return (*rlocker)(rw)
}