MCPcopy Create free account
hub / github.com/google/gapid / Append

Function Append

core/data/slice/slice.go:78–81  ·  view source on GitHub ↗

Append appends s with v. s must be a pointer to a slice. v can be a slice or a single element.

(s interface{}, v interface{})

Source from the content-addressed store, hash-verified

76// s must be a pointer to a slice.
77// v can be a slice or a single element.
78func Append(s interface{}, v interface{}) {
79 ptr, old := getSlicePtr(s)
80 replace(ptr, old, old.Len(), 0, v)
81}
82
83// Clone returns a shallow copy of the slice s.
84func Clone(s interface{}) interface{} {

Callers

nothing calls this directly

Calls 3

getSlicePtrFunction · 0.85
replaceFunction · 0.70
LenMethod · 0.65

Tested by

no test coverage detected