mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-13 21:35:39 +00:00
bug 534493 - avoiding too much debug checks in JSScope::removeProperty. r=brendan
This commit is contained in:
parent
2c1104d609
commit
cdb4827341
@ -1594,7 +1594,13 @@ JSScope::removeProperty(JSContext *cx, jsid id)
|
||||
if (table) {
|
||||
*spp = NULL;
|
||||
#ifdef DEBUG
|
||||
for (JSScopeProperty *aprop = lastProp; aprop; aprop = aprop->parent)
|
||||
/*
|
||||
* Check the consistency of the table but limit the number of
|
||||
* checks not to alter significantly the complexity of the delete
|
||||
* in debug builds, see bug 534493.
|
||||
*/
|
||||
JSScopeProperty *aprop = lastProp;
|
||||
for (unsigned n = 50; aprop && n != 0; aprop = aprop->parent, --n)
|
||||
JS_ASSERT_IF(aprop != sprop, hasProperty(aprop));
|
||||
#endif
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user