Open
Bug 1379216
Opened 7 years ago
Updated 2 years ago
Don't save a strong reference in HTMLTableElement::Rows()
Categories
(Core :: DOM: Core & HTML, enhancement, P3)
Core
DOM: Core & HTML
Tracking
()
NEW
People
(Reporter: ehsan.akhgari, Unassigned)
Details
This is similar to bug 1377560, although bug 1378201 is making this code not use nsContentLists. But it would be nice to not have a strong ref here for similar reasons.
Comment 1•7 years ago
|
||
We'd need to make sure that something like this doesn't cause the creation of a new TableRowsCollection: for (let i = 0; i < table.rows.length; ++i) { doSomeWork(); } I imagine in a situation like this we'd really want to not create a new rows object every iteration (or every few iterations) of the loop, as creating one is expensive. That being said, we also don't want to keep our rows object alive indefinitely. I'm not sure how we can intelligently make a decision about this.
Reporter | ||
Comment 2•7 years ago
|
||
The object is held alive by the cycle collector I believe so it will stay alive during such a loop without us needing to do anything. But yes it's worth double checking that the assumption indeed holds!
Updated•7 years ago
|
Priority: -- → P2
Comment 3•6 years ago
|
||
Moving to p3 because no activity for at least 1 year(s). See https://github.com/mozilla/bug-handling/blob/master/policy/triage-bugzilla.md#how-do-you-triage for more information
Priority: P2 → P3
Assignee | ||
Updated•5 years ago
|
Component: DOM → DOM: Core & HTML
Updated•2 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•