Commit de1ea5de authored by Rui Ueyama's avatar Rui Ueyama Committed by Brad Fitzpatrick

strings: minor cleanup

bi is a slice and not an array, so bi[:] does not make much sense.

LGTM=bradfitz
R=golang-codereviews, bradfitz
CC=golang-codereviews
https://golang.org/cl/79280043
parent 9cb4963d
......@@ -492,7 +492,7 @@ func (r *byteStringReplacer) Replace(s string) string {
for i := 0; i < len(s); i++ {
b := s[i]
if r.old[b>>5]&uint32(1<<(b&31)) != 0 {
n := copy(bi[:], r.new[b])
n := copy(bi, r.new[b])
bi = bi[n:]
} else {
bi[0] = b
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment