go/src/strings
Joe Tsai 9a4685f220 strings: avoid utf8.RuneError mangling in Split
Split should only split strings and not perform mangling
of invalid UTF-8 into ut8.RuneError.
The prior behavior is clearly a bug since mangling is not
performed in all other situations (e.g., separator is non-empty).

Fixes #53511

Change-Id: I112a2ef15ee46ddecda015ee14bca04cd76adfbf
Reviewed-on: https://go-review.googlesource.com/c/go/+/413715
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Run-TryBot: Ian Lance Taylor <iant@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
2022-08-08 20:44:51 +00:00
..
builder.go all: separate doc comment from //go: directives 2022-04-05 17:54:15 +00:00
builder_test.go
clone.go
clone_test.go
compare.go
compare_test.go
example_test.go strings: document the use of simple case-folding in EqualFold 2022-04-02 06:48:45 +00:00
export_test.go all: gofmt -w -r 'interface{} -> any' src 2021-12-13 18:45:54 +00:00
reader.go
reader_test.go all: gofmt -w -r 'interface{} -> any' src 2021-12-13 18:45:54 +00:00
replace.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
replace_test.go
search.go
search_test.go
strings.go strings: avoid utf8.RuneError mangling in Split 2022-08-08 20:44:51 +00:00
strings_test.go strings: avoid utf8.RuneError mangling in Split 2022-08-08 20:44:51 +00:00