Closed Bug 92256 Opened 23 years ago Closed 12 years ago

Tracking bug: nsVoidArray->nsAutoVoidArray, nsCStringArray

Categories

(Core :: XPCOM, defect)

defect
Not set
normal

Tracking

()

RESOLVED WONTFIX

People

(Reporter: jesup, Unassigned)

References

Details

(Keywords: meta, perf)

Many uses of nsVoidArray would be better served by using nsAutoVoidArray,
especially if we know that there will (likely) be a small number of items in the
array.  nsVoidArray makes more sense when it's unlikely there will be any
entries (especially if there are a lot of these objects), or if it's likely
there will be more than 8.  In other cases, it makes sense (if the size is known
ahead of time or guessable and is larger than 8) to use nsVoidArray(size).

nsStringArray/nsCStringArray can also benefit by using initializers when the
size is known.

See bug 90545 for examples in the patch; it fixed many cases of this.
I'll take this one.
Assignee: kandrot → rjesup
Depends on: 90545
Priority: -- → P2
Keywords: perf
Depends on: 92534
Depends on: 92535
Depends on: 92543
Patches split off from bug 90545:

Layout: bug 92573; content: bug 92575; all others: bug 92576.
Depends on: 92573, 92575, 92576
Depends on: 92614
Blocks: 67618
Blocks: 7251
Bug 94243 is the bug for the remaining pieces of 90545
Status: NEW → ASSIGNED
Depends on: 94243
Adding a lonely nsVoidArray->nsAutoVoidArray bug which may or may not have been
cleaned up.
Depends on: 80210
Assignee: rjesup → nobody
Status: ASSIGNED → NEW
QA Contact: scc → xpcom
If there are no more open dependencies, should this bug be closed?
Keywords: meta
Priority: P2 → --
(In reply to comment #5)

+1

Close? 3 years have passed.
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.