Test name | Executions per second |
---|---|
test truth | 245539008.0 Ops/sec |
test undefined | 7262662.0 Ops/sec |
test hasOwnProperty | 53511724.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;
}