mirror of
https://github.com/golang/go.git
synced 2025-05-05 23:53:05 +00:00
It maybe a typo
parent
19a3e9c4e3
commit
75c3834c67
@ -103,7 +103,7 @@ s[i] = x
|
|||||||
|
|
||||||
#### InsertVector
|
#### InsertVector
|
||||||
```go
|
```go
|
||||||
a = append(a[:i], append(b, a[i:]...)...)
|
a = append(a[:i], append([]T{b}, a[i:]...)...)
|
||||||
|
|
||||||
// The above one-line way copies a[i:] twice and
|
// The above one-line way copies a[i:] twice and
|
||||||
// allocates at least once.
|
// allocates at least once.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user