MCPcopy Create free account
hub / github.com/cujojs/poly / hasDefineProperties

Function hasDefineProperties

object.js:237–246  ·  view source on GitHub ↗
(object)

Source from the content-addressed store, hash-verified

235 // Note: MSDN docs say that IE8 has this function, but tests show
236 // that it does not! JMH
237 function hasDefineProperties (object) {
238 if (('defineProperties' in Object)) {
239 try {
240 // test it
241 Object.defineProperties(object, { 'sentinel2': { value: 1 } })
242 return 'sentinel2' in object;
243 }
244 catch (ex) { /* squelch */ }
245 }
246 }
247
248 function hasGetOwnPropertyDescriptor (object) {
249 if (('getOwnPropertyDescriptor' in Object)) {

Callers 1

object.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected