]> Cypherpunks repositories - gostls13.git/commitdiff
sync: refer to Locker interface methods in RWMutex.RLocker doc
authorDmitri Shuralyov <dmitshur@golang.org>
Sat, 29 Jun 2024 20:35:40 +0000 (20:35 +0000)
committerGopher Robot <gobot@golang.org>
Mon, 1 Jul 2024 13:44:22 +0000 (13:44 +0000)
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>
src/sync/rwmutex.go

index 66cb93c44efe7ce3268fbb9dedda62d5669a6ae8..1d5b8fde4a8c627a5c6c7840741e46ee9ffcc173 100644 (file)
@@ -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)
 }