mirror of
https://github.com/golang/go
synced 2024-11-21 12:54:45 -07:00
doc/articles/slices_usage_and_internals: fix typo
Fixes #3753. R=golang-dev, adg CC=golang-dev https://golang.org/cl/6304097
This commit is contained in:
parent
d4c4f4d2c4
commit
5d2cfc2faa
@ -243,7 +243,7 @@ slice itself) of a re-slice modifies the elements of the original slice:
|
||||
d := []byte{'r', 'o', 'a', 'd'}
|
||||
e := d[2:]
|
||||
// e == []byte{'a', 'd'}
|
||||
e[1] == 'm'
|
||||
e[1] = 'm'
|
||||
// e == []byte{'a', 'm'}
|
||||
// d == []byte{'r', 'o', 'a', 'm'}
|
||||
</pre>
|
||||
|
Loading…
Reference in New Issue
Block a user