]> Cypherpunks repositories - gostls13.git/commitdiff
errors: clarify Join documentation
authorDavid Bendory <bendory@users.noreply.github.com>
Fri, 17 Mar 2023 14:04:01 +0000 (14:04 +0000)
committerGopher Robot <gobot@golang.org>
Fri, 17 Mar 2023 21:12:15 +0000 (21:12 +0000)
The previous documentation used a double-negative in describing Join behavior; this use of language could be confusing.

This update removes the double-negative.

Change-Id: If13e88682e865314a556e7d381143a97fa5486d9
GitHub-Last-Rev: 92b3f88a5d49229e71adafcfa7b1d01dcb7646f3
GitHub-Pull-Request: golang/go#59082
Reviewed-on: https://go-review.googlesource.com/c/go/+/477095
Auto-Submit: Ian Lance Taylor <iant@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Damien Neil <dneil@google.com>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Run-TryBot: Ian Lance Taylor <iant@google.com>

src/errors/join.go

index dc5a716aa6f5010a0158c9fcf987c871bdd09c31..329082a5e3b481dd195398750e6bec41346930f6 100644 (file)
@@ -6,7 +6,7 @@ package errors
 
 // Join returns an error that wraps the given errors.
 // Any nil error values are discarded.
-// Join returns nil if errs contains no non-nil values.
+// Join returns nil if every value in errs is nil.
 // The error formats as the concatenation of the strings obtained
 // by calling the Error method of each element of errs, with a newline
 // between each string.