<feed xmlns='http://www.w3.org/2005/Atom'>
<title>go/src/bytes/example_test.go, branch fix-runtime-test-GOMAXPROCS</title>
<subtitle>Fork of Go programming language with my patches.</subtitle>
<id>http://git.kilabit.info/go/atom?h=fix-runtime-test-GOMAXPROCS</id>
<link rel='self' href='http://git.kilabit.info/go/atom?h=fix-runtime-test-GOMAXPROCS'/>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/'/>
<updated>2025-05-12T16:07:54Z</updated>
<entry>
<title>bytes, strings: rename parameters in ExampleCut{Pre,Suf}fix</title>
<updated>2025-05-12T16:07:54Z</updated>
<author>
<name>Tobias Klauser</name>
<email>tklauser@distanz.ch</email>
</author>
<published>2025-05-08T12:13:16Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=238d273da4859fe4be5db019879fdb886a547350'/>
<id>urn:sha1:238d273da4859fe4be5db019879fdb886a547350</id>
<content type='text'>
The old parameter name sep was probably copied from ExampleCut. Change
the parameter names to prefix and suffix, respectivly to make the
examples a bit more readable.

Change-Id: Ie14b0050c2fafe3301c5368efd548a1629a7545f
Reviewed-on: https://go-review.googlesource.com/c/go/+/670955
Auto-Submit: Tobias Klauser &lt;tobias.klauser@gmail.com&gt;
LUCI-TryBot-Result: Go LUCI &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
Reviewed-by: Michael Knyszek &lt;mknyszek@google.com&gt;
Reviewed-by: Sean Liao &lt;sean@liao.dev&gt;
Reviewed-by: Robert Griesemer &lt;gri@google.com&gt;
</content>
</entry>
<entry>
<title>bytes: add examples for Lines, SplitSeq, SplitAfterSeq, FieldsSeq and FieldsFuncSeq</title>
<updated>2025-02-14T23:18:41Z</updated>
<author>
<name>cuishuang</name>
<email>imcusg@gmail.com</email>
</author>
<published>2025-02-13T07:28:21Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=2299a4289d69c71573fd22350eea0677639e563c'/>
<id>urn:sha1:2299a4289d69c71573fd22350eea0677639e563c</id>
<content type='text'>
Change-Id: I0e755d5c73f14d2c98853bdd31a7f2e84c92a906
Reviewed-on: https://go-review.googlesource.com/c/go/+/648860
Reviewed-by: Ian Lance Taylor &lt;iant@google.com&gt;
Auto-Submit: Ian Lance Taylor &lt;iant@google.com&gt;
Reviewed-by: Dmitri Shuralyov &lt;dmitshur@google.com&gt;
LUCI-TryBot-Result: Go LUCI &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
</content>
</entry>
<entry>
<title>bytes,strings: use a more universal Cyrillic word</title>
<updated>2024-08-07T17:22:36Z</updated>
<author>
<name>Oleksandr Redko</name>
<email>oleksandr.red+github@gmail.com</email>
</author>
<published>2024-08-06T17:16:42Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=5a81570bf2dfd7698d8ae6b3f9f3addd4161d453'/>
<id>urn:sha1:5a81570bf2dfd7698d8ae6b3f9f3addd4161d453</id>
<content type='text'>
The word "брат" (brother) is the same across Slavic languages that
use the Cyrillic script, such as Bulgarian, Macedonian, Russian,
Ukrainian, and others.

Change-Id: I5155e6bb16a02dec5d93a01b79f9570f43f09444
Reviewed-on: https://go-review.googlesource.com/c/go/+/603535
Reviewed-by: Robert Griesemer &lt;gri@google.com&gt;
LUCI-TryBot-Result: Go LUCI &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
Auto-Submit: Robert Griesemer &lt;gri@google.com&gt;
Reviewed-by: David Chase &lt;drchase@google.com&gt;
</content>
</entry>
<entry>
<title>all: change from sort functions to slices functions where feasible</title>
<updated>2024-05-23T01:00:11Z</updated>
<author>
<name>Ian Lance Taylor</name>
<email>iant@golang.org</email>
</author>
<published>2024-05-22T20:38:40Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=b0b1d42db32a992150dd26681d3bda222e108303'/>
<id>urn:sha1:b0b1d42db32a992150dd26681d3bda222e108303</id>
<content type='text'>
Doing this because the slices functions are slightly faster and
slightly easier to use. It also removes one dependency layer.

This CL does not change packages that are used during bootstrap,
as the bootstrap compiler does not have the required slices functions.
It does not change the go/scanner package because the ErrorList
Len, Swap, and Less methods are part of the Go 1 API.

Change-Id: If52899be791c829198e11d2408727720b91ebe8a
Reviewed-on: https://go-review.googlesource.com/c/go/+/587655
LUCI-TryBot-Result: Go LUCI &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
Reviewed-by: Ian Lance Taylor &lt;iant@google.com&gt;
Auto-Submit: Ian Lance Taylor &lt;iant@google.com&gt;
Commit-Queue: Ian Lance Taylor &lt;iant@google.com&gt;
Reviewed-by: Damien Neil &lt;dneil@google.com&gt;
</content>
</entry>
<entry>
<title>bytes: add a colon after Output to make the Example in the document display correctly</title>
<updated>2024-03-04T15:54:40Z</updated>
<author>
<name>cui fliter</name>
<email>imcusg@gmail.com</email>
</author>
<published>2024-02-29T08:09:31Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=a5f8ae9f6566946529a51b69d2f3f0689abc00eb'/>
<id>urn:sha1:a5f8ae9f6566946529a51b69d2f3f0689abc00eb</id>
<content type='text'>
The document address currently showing the problem is: https://pkg.go.dev/bytes#Buffer.ReadByte

Change-Id: Ib52747e38f72541f3ca2a595aa8eca5d91281c80
Reviewed-on: https://go-review.googlesource.com/c/go/+/568135
Auto-Submit: Ian Lance Taylor &lt;iant@google.com&gt;
LUCI-TryBot-Result: Go LUCI &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
Run-TryBot: shuang cui &lt;imcusg@gmail.com&gt;
TryBot-Result: Gopher Robot &lt;gobot@golang.org&gt;
Reviewed-by: Ian Lance Taylor &lt;iant@google.com&gt;
Reviewed-by: Bryan Mills &lt;bcmills@google.com&gt;
</content>
</entry>
<entry>
<title>bytes,strings: add example for ContainsFunc</title>
<updated>2023-10-09T22:05:38Z</updated>
<author>
<name>cui fliter</name>
<email>imcusg@gmail.com</email>
</author>
<published>2023-10-08T08:42:26Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=8f61fab61862e0c8f8bb8db968d14c262ff54d4c'/>
<id>urn:sha1:8f61fab61862e0c8f8bb8db968d14c262ff54d4c</id>
<content type='text'>
Change-Id: I340e892aa4ecc780905be984016efc86699a45a2
Reviewed-on: https://go-review.googlesource.com/c/go/+/533556
Run-TryBot: shuang cui &lt;imcusg@gmail.com&gt;
Reviewed-by: qiulaidongfeng &lt;2645477756@qq.com&gt;
Reviewed-by: Ian Lance Taylor &lt;iant@google.com&gt;
TryBot-Result: Gopher Robot &lt;gobot@golang.org&gt;
LUCI-TryBot-Result: Go LUCI &lt;golang-scoped@luci-project-accounts.iam.gserviceaccount.com&gt;
Reviewed-by: Mauri de Souza Meneguzzo &lt;mauri870@gmail.com&gt;
Reviewed-by: Dmitri Shuralyov &lt;dmitshur@google.com&gt;
Auto-Submit: Ian Lance Taylor &lt;iant@google.com&gt;
</content>
</entry>
<entry>
<title>all: remove redundant string conversions when formatting []byte with %s</title>
<updated>2023-08-22T22:52:37Z</updated>
<author>
<name>cui fliter</name>
<email>imcusg@gmail.com</email>
</author>
<published>2023-08-20T10:33:50Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=0163b3b32cad2ed3331e2b197c68387f12246cd8'/>
<id>urn:sha1:0163b3b32cad2ed3331e2b197c68387f12246cd8</id>
<content type='text'>
Change-Id: I603051a3174b139ffb81d20d42979c7f3f04a09a
Reviewed-on: https://go-review.googlesource.com/c/go/+/521136
Run-TryBot: Filippo Valsorda &lt;filippo@golang.org&gt;
Auto-Submit: Ian Lance Taylor &lt;iant@google.com&gt;
Reviewed-by: Ian Lance Taylor &lt;iant@google.com&gt;
Run-TryBot: Ian Lance Taylor &lt;iant@google.com&gt;
Reviewed-by: Bryan Mills &lt;bcmills@google.com&gt;
Run-TryBot: shuang cui &lt;imcusg@gmail.com&gt;
Reviewed-by: Filippo Valsorda &lt;filippo@golang.org&gt;
TryBot-Result: Gopher Robot &lt;gobot@golang.org&gt;
</content>
</entry>
<entry>
<title>bytes: add Buffer.Available and Buffer.AvailableBuffer</title>
<updated>2023-03-13T17:03:14Z</updated>
<author>
<name>Joe Tsai</name>
<email>joetsai@digital-static.net</email>
</author>
<published>2023-02-06T19:37:39Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=e671fe0c3efc497397af3362a4b79c895fbd8bfc'/>
<id>urn:sha1:e671fe0c3efc497397af3362a4b79c895fbd8bfc</id>
<content type='text'>
This adds a new Buffer.AvailableBuffer method that returns
an empty buffer with a possibly non-empty capacity for use
with append-like APIs.

The typical usage pattern is something like:

	b := bb.AvailableBuffer()
	b = appendValue(b, v)
	bb.Write(b)

It allows logic combining append-like APIs with Buffer
to avoid needing to allocate and manage buffers themselves and
allows the append-like APIs to directly write into the Buffer.

The Buffer.Write method uses the builtin copy function,
which avoids copying bytes if the source and destination are identical.
Thus, Buffer.Write is a constant-time call for this pattern.

Performance:

	BenchmarkBufferAppendNoCopy  2.909 ns/op  5766942167.24 MB/s

This benchmark should only be testing the cost of bookkeeping
and never the copying of the input slice.
Thus, the MB/s should be orders of magnitude faster than RAM.

Fixes #53685

Change-Id: I0b41e54361339df309db8d03527689b123f99085
Reviewed-on: https://go-review.googlesource.com/c/go/+/474635
Run-TryBot: Joseph Tsai &lt;joetsai@digital-static.net&gt;
Reviewed-by: Daniel Martí &lt;mvdan@mvdan.cc&gt;
Reviewed-by: Cherry Mui &lt;cherryyz@google.com&gt;
TryBot-Result: Gopher Robot &lt;gobot@golang.org&gt;
Auto-Submit: Joseph Tsai &lt;joetsai@digital-static.net&gt;
Reviewed-by: Ian Lance Taylor &lt;iant@google.com&gt;
</content>
</entry>
<entry>
<title>bytes,strings: add some examples</title>
<updated>2023-01-20T23:21:39Z</updated>
<author>
<name>fangguizhen</name>
<email>1297394526@qq.com</email>
</author>
<published>2023-01-20T09:43:40Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=85b49d7f21dfbee9946bece01a168de239094716'/>
<id>urn:sha1:85b49d7f21dfbee9946bece01a168de239094716</id>
<content type='text'>
Change-Id: Ic93ad59119f3549c0f13c4f366f71e9d01b88c47
GitHub-Last-Rev: afb518047288976f440d3fe0d65923c1905a9b26
GitHub-Pull-Request: golang/go#57907
Reviewed-on: https://go-review.googlesource.com/c/go/+/462283
TryBot-Result: Gopher Robot &lt;gobot@golang.org&gt;
Run-TryBot: Ian Lance Taylor &lt;iant@google.com&gt;
Reviewed-by: Ian Lance Taylor &lt;iant@google.com&gt;
Reviewed-by: Cherry Mui &lt;cherryyz@google.com&gt;
Run-TryBot: Ian Lance Taylor &lt;iant@golang.org&gt;
Auto-Submit: Ian Lance Taylor &lt;iant@google.com&gt;
</content>
</entry>
<entry>
<title>bytes: add example with (*Buffer).Cap, (*Buffer).Read, (*Buffer).ReadByte</title>
<updated>2021-11-05T21:26:54Z</updated>
<author>
<name>jiahua wang</name>
<email>wjh180909@gmail.com</email>
</author>
<published>2021-10-12T06:27:02Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/go/commit/?id=3e9e02412e7770e46c7e725e17dee09a7d79f32c'/>
<id>urn:sha1:3e9e02412e7770e46c7e725e17dee09a7d79f32c</id>
<content type='text'>
Change-Id: Ieb107fdfccde9f054491f667a384b16f7af71dea
Reviewed-on: https://go-review.googlesource.com/c/go/+/355289
Run-TryBot: Ian Lance Taylor &lt;iant@golang.org&gt;
TryBot-Result: Go Bot &lt;gobot@golang.org&gt;
Reviewed-by: Ian Lance Taylor &lt;iant@golang.org&gt;
Trust: Cherry Mui &lt;cherryyz@google.com&gt;
</content>
</entry>
</feed>
