Test name | Executions per second |
---|---|
test truth | 86085808.0 Ops/sec |
test undefined | 6776846.5 Ops/sec |
test hasOwnProperty | 47493084.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;
}