go/src/bytes
Ian Lance Taylor 32fdad19a2 bytes: restore old Trim/TrimLeft behavior for nil
Keep returning nil for the cases where we historically returned nil,
even though this is slightly different for TrimLeft and TrimRight.

Fixes #51793

Change-Id: Ifbdfc6b09d52b8e063cfe6341019f9b2eb8b70e9
Reviewed-on: https://go-review.googlesource.com/c/go/+/393876
Trust: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Keith Randall <khr@golang.org>
2022-03-28 22:06:49 +00:00
..
boundary_test.go bytes: test for page boundary crosses on sep of Index 2021-11-02 17:31:50 +00:00
buffer.go bytes: rely on runtime.growslice for growing 2022-03-10 16:24:16 +00:00
buffer_test.go bytes: rely on runtime.growslice for growing 2022-03-10 16:24:16 +00:00
bytes.go bytes: restore old Trim/TrimLeft behavior for nil 2022-03-28 22:06:49 +00:00
bytes_test.go bytes: restore old Trim/TrimLeft behavior for nil 2022-03-28 22:06:49 +00:00
compare_test.go bytes: add endian base compare test 2019-10-07 14:49:57 +00:00
example_test.go bytes: add example with (*Buffer).Cap, (*Buffer).Read, (*Buffer).ReadByte 2021-11-05 21:26:54 +00:00
export_test.go bytes, internal/bytealg: simplify Equal 2019-04-24 00:56:36 +00:00
reader.go bytes, strings: fix Reader.UnreadRune returning without error on a zero Reader 2018-10-29 20:07:25 +00:00
reader_test.go all: gofmt -w -r 'interface{} -> any' src 2021-12-13 18:45:54 +00:00