doc: mention change in append behavior

Introduced in CL 347917.

Change-Id: I99b34341f787e779bd45b967110e70a035fa6558
Reviewed-on: https://go-review.googlesource.com/c/go/+/386217
Trust: Keith Randall <khr@golang.org>
Run-TryBot: Keith Randall <khr@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Martin Möhrmann <martin@golang.org>
Trust: Martin Möhrmann <martin@golang.org>
Run-TryBot: Martin Möhrmann <martin@golang.org>
This commit is contained in:
Keith Randall 2022-02-17 09:37:07 -08:00 committed by Carlos Amedee
parent fc5b64e19b
commit 9eb14f1b0e

View file

@ -512,6 +512,12 @@ For more information, see <a href="https://go.dev/design/draft-gobuild">https://
after each value that may be inaccurate.
</p>
<p><!-- CL 347917 -->
The built-in function <code>append</code> now uses a slightly different formula
when deciding how much to grow a slice when it must allocate a new underlying array.
The new formula is less prone to sudden transitions in allocation behavior.
</p>
<h2 id="compiler">Compiler</h2>
<p><!-- https://golang.org/issue/40724 -->