mirror of
https://github.com/golang/go
synced 2024-11-23 07:30:05 -07:00
strings: revert accidental example change from CL 153840
Change-Id: I2ff29aa9909be3062fcd5f65af261f5d8c46fbc1 Reviewed-on: https://go-review.googlesource.com/c/153843 Reviewed-by: Ian Lance Taylor <iant@golang.org> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
This commit is contained in:
parent
ab02028b5a
commit
e123ccbfe0
@ -199,7 +199,7 @@ func ExampleRepeat() {
|
||||
|
||||
func ExampleReplace() {
|
||||
fmt.Println(strings.Replace("oink oink oink", "k", "ky", 2))
|
||||
fmt.Println(strings.ReplaceAll("oink oink oink", "oink", "moo"))
|
||||
fmt.Println(strings.Replace("oink oink oink", "oink", "moo", -1))
|
||||
// Output:
|
||||
// oinky oinky oink
|
||||
// moo moo moo
|
||||
|
Loading…
Reference in New Issue
Block a user