mirror of https://github.com/golang/go.git
sync: make clear that WaitGroup.Done decrements by one
Change-Id: Ief076151739147378f8ca35cd09aabb59c3c9a52 Reviewed-on: https://go-review.googlesource.com/46350 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This commit is contained in:
parent
ded29e7b39
commit
4b4bb53bf3
|
|
@ -95,7 +95,7 @@ func (wg *WaitGroup) Add(delta int) {
|
|||
}
|
||||
}
|
||||
|
||||
// Done decrements the WaitGroup counter.
|
||||
// Done decrements the WaitGroup counter by one.
|
||||
func (wg *WaitGroup) Done() {
|
||||
wg.Add(-1)
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue