Closed
Bug 602477
Opened 14 years ago
Closed 9 years ago
Investigate what looks like dead code in array_lookupProperty
Categories
(Core :: JavaScript Engine, defect)
Tracking
()
RESOLVED
DUPLICATE
of bug 827490
People
(Reporter: bzbarsky, Unassigned)
Details
Two things:
1) This is the jsops hook for js_ArrayClass. Is it even possible for
obj->isDenseArray() to be false on entry to this function?
2) Given obj->isDenseArray(), I would think that obj->getProto() is guaranteed
non-null. Why do we need that null check?
In other words, I think the entirety of the function can look like this:
if (IsDenseArrayId(cx, obj, id)) {
*propp = (JSProperty *) 1; /* non-null to indicate found */
*objp = obj;
return JS_TRUE;
}
return obj->getProto()->lookupProperty(cx, id, objp, propp);
Assignee | ||
Updated•10 years ago
|
Assignee: general → nobody
Comment 1•9 years ago
|
||
array_lookupProperty was removed in http://hg.mozilla.org/mozilla-central/rev/f4671ccc4502
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•