MCPcopy Create free account
hub / github.com/dop251/goja / createArrayIterator

Method createArrayIterator

array.go:48–63  ·  view source on GitHub ↗
(iterObj *Object, kind iterationKind)

Source from the content-addressed store, hash-verified

46}
47
48func (r *Runtime) createArrayIterator(iterObj *Object, kind iterationKind) Value {
49 o := &Object{runtime: r}
50
51 ai := &arrayIterObject{
52 obj: iterObj,
53 kind: kind,
54 }
55 ai.class = classObject
56 ai.val = o
57 ai.extensible = true
58 o.self = ai
59 ai.prototype = r.getArrayIteratorPrototype()
60 ai.init()
61
62 return o
63}
64
65type arrayObject struct {
66 baseObject

Callers 6

arrayproto_valuesMethod · 0.95
arrayproto_keysMethod · 0.95
arrayproto_entriesMethod · 0.95
typedArrayProto_keysMethod · 0.95

Calls 2

initMethod · 0.65

Tested by

no test coverage detected