]> Cypherpunks repositories - gostls13.git/commitdiff
sync: consistently use article "a" for RWMutex
authorBrad Fitzpatrick <bradfitz@golang.org>
Tue, 16 Jan 2018 22:57:44 +0000 (22:57 +0000)
committerAndrew Bonventre <andybons@golang.org>
Tue, 16 Jan 2018 23:09:57 +0000 (23:09 +0000)
We used a mix of both before.

I've never heard anybody say "an arr-double you mutex" when speaking.

Fixes #23457

Change-Id: I802b5eb2339f885ca9d24607eeda565763165298
Reviewed-on: https://go-review.googlesource.com/87896
Reviewed-by: Andrew Bonventre <andybons@golang.org>
src/runtime/rwmutex.go
src/sync/rwmutex.go

index 7eeb559adb5b321fc93705b54932e77a7294f957..a6da4c979ba21e69b049084a89430243f4a640dd 100644 (file)
@@ -10,7 +10,7 @@ import (
 
 // This is a copy of sync/rwmutex.go rewritten to work in the runtime.
 
-// An rwmutex is a reader/writer mutual exclusion lock.
+// A rwmutex is a reader/writer mutual exclusion lock.
 // The lock can be held by an arbitrary number of readers or a single writer.
 // This is a variant of sync.RWMutex, for the runtime package.
 // Like mutex, rwmutex blocks the calling M.
index cb2dfe1ad8dd9610866f57460985817261534f26..4e9e8197c145590201d0df65c304332d76011a6e 100644 (file)
@@ -13,11 +13,11 @@ import (
 // There is a modified copy of this file in runtime/rwmutex.go.
 // If you make any changes here, see if you should make them there.
 
-// An RWMutex is a reader/writer mutual exclusion lock.
+// A RWMutex is a reader/writer mutual exclusion lock.
 // The lock can be held by an arbitrary number of readers or a single writer.
 // The zero value for a RWMutex is an unlocked mutex.
 //
-// An RWMutex must not be copied after first use.
+// A RWMutex must not be copied after first use.
 //
 // If a goroutine holds a RWMutex for reading and another goroutine might
 // call Lock, no goroutine should expect to be able to acquire a read lock
@@ -108,7 +108,7 @@ func (rw *RWMutex) Lock() {
 // not locked for writing on entry to Unlock.
 //
 // As with Mutexes, a locked RWMutex is not associated with a particular
-// goroutine. One goroutine may RLock (Lock) an RWMutex and then
+// goroutine. One goroutine may RLock (Lock) a RWMutex and then
 // arrange for another goroutine to RUnlock (Unlock) it.
 func (rw *RWMutex) Unlock() {
        if race.Enabled {