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

Method hasPropertyIdx

array_sparse.go:305–315  ·  view source on GitHub ↗
(idx valueInt)

Source from the content-addressed store, hash-verified

303}
304
305func (a *sparseArrayObject) hasPropertyIdx(idx valueInt) bool {
306 if a.hasOwnPropertyIdx(idx) {
307 return true
308 }
309
310 if a.prototype != nil {
311 return a.prototype.self.hasPropertyIdx(idx)
312 }
313
314 return false
315}
316
317func (a *sparseArrayObject) expand(idx uint32) bool {
318 if l := len(a.items); l >= 1024 {

Callers

nothing calls this directly

Calls 2

hasOwnPropertyIdxMethod · 0.95
hasPropertyIdxMethod · 0.65

Tested by

no test coverage detected