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

Method hasPropertyIdx

array.go:335–345  ·  view source on GitHub ↗
(idx valueInt)

Source from the content-addressed store, hash-verified

333}
334
335func (a *arrayObject) hasPropertyIdx(idx valueInt) bool {
336 if a.hasOwnPropertyIdx(idx) {
337 return true
338 }
339
340 if a.prototype != nil {
341 return a.prototype.self.hasPropertyIdx(idx)
342 }
343
344 return false
345}
346
347func (a *arrayObject) expand(idx uint32) bool {
348 targetLen := idx + 1

Callers

nothing calls this directly

Calls 2

hasOwnPropertyIdxMethod · 0.95
hasPropertyIdxMethod · 0.65

Tested by

no test coverage detected