Test name | Executions per second |
---|---|
test false | 910495552.0 Ops/sec |
test undefined | 8206510.5 Ops/sec |
test hasOwnProperty | 82674992.0 Ops/sec |
test == null | 905790848.0 Ops/sec |
test == undefined | 8092202.5 Ops/sec |
test static hasOwnProperty | 3562475.2 Ops/sec |
test static hasOwn | 7572862.0 Ops/sec |
var n = {};
while(true) {
if(!n.foo)
break;
}
var n = {};
while(true) {
if(n.foo===undefined)
break;
}
var n = {};
while(true) {
if(!n.hasOwnProperty('foo'))
break;
}
var n = {};
while(true) {
if(n.foo==null)
break;
}
var n = {};
while(true) {
if(n.foo==undefined)
break;
}
var n = {};
while(true) {
if(!Object.hasOwnProperty(n,'foo'))
break;
}
var n = {};
while(true) {
if(!Object.hasOwn(n, 'foo'))
break;
}