aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@golang.org>2016-07-10 21:47:56 -0700
committerIan Lance Taylor <iant@golang.org>2016-07-11 17:19:26 +0000
commit38de5b71f274ff93581a302b2f3ec4b9937afa51 (patch)
tree168d0c33e32a2f0f016d72424736950d1dbf03da
parentfb3cf5c686b09bab8c1bef5f7589aaef0e6d9712 (diff)
downloadgo-38de5b71f274ff93581a302b2f3ec4b9937afa51.tar.gz
go-38de5b71f274ff93581a302b2f3ec4b9937afa51.zip
doc/go1.7.html: no concurrent calls of math/rand methods
A follow-on to https://golang.org/cl/24852 that mentions the documentation clarifications. Updates #16308. Change-Id: Ic2a6e1d4938d74352f93a6649021fb610efbfcd0 Reviewed-on: https://go-review.googlesource.com/24857 Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Joe Tsai <thebrokentoaster@gmail.com> Reviewed-by: Josh Bleecher Snyder <josharian@gmail.com>
-rw-r--r--doc/go1.7.html10
1 files changed, 10 insertions, 0 deletions
diff --git a/doc/go1.7.html b/doc/go1.7.html
index 2a2675e98a..6605e4b366 100644
--- a/doc/go1.7.html
+++ b/doc/go1.7.html
@@ -793,6 +793,16 @@ The
now produce a pseudo-random stream of bytes that is consistent and not
dependent on the size of the input buffer.
</p>
+
+<p>
+The documentation clarifies that
+Rand's <a href="/pkg/math/rand/#Rand.Seed"><code>Seed</code></a>
+and <a href="/pkg/math/rand/#Rand.Read"><code>Read</code></a> methods
+are not safe to call concurrently, though the global
+functions <a href="/pkg/math/rand/#Seed"><code>Seed</code></a>
+and <a href="/pkg/math/rand/#Read"><code>Read</code></a> are (and have
+always been) safe.
+</p>
</dd>
</dl>