Closed
Bug 258098
Opened 21 years ago
Closed 18 years ago
nsValueArray needs a SetSize()
Categories
(Core :: XPCOM, defect)
Core
XPCOM
Tracking
()
RESOLVED
WONTFIX
People
(Reporter: csthomas, Assigned: regis.caspar+bz)
References
Details
Attachments
(2 files, 1 obsolete file)
|
11.79 KB,
patch
|
benjamin
:
review-
|
Details | Diff | Splinter Review |
|
4.49 KB,
text/plain
|
Details |
<CTho> do we need to implement a setsize for nsvaluearray?
<NeilZZZ> it looks like it, the reverse code needs it and the thread sort code
needs it
<CTho> so setsize needs to either truncate or grow and fill with empty values?
<NeilZZZ> right... not as easy as replace was
| Reporter | ||
Updated•21 years ago
|
Whiteboard: waiting on 258058 so I don't bitrot my own patches
Updated•21 years ago
|
Product: Browser → Seamonkey
| Reporter | ||
Updated•21 years ago
|
Whiteboard: waiting on 258058 so I don't bitrot my own patches → helpwanted, waiting on 258058 to not bitrot patches
| Reporter | ||
Updated•21 years ago
|
Assignee: cst → general
Whiteboard: helpwanted, waiting on 258058 to not bitrot patches → helpwanted
Target Milestone: --- → Future
| Assignee | ||
Comment 1•18 years ago
|
||
Attached a patch proposal. Is it normal that the [] operator fails (returns a pointer (?) here and not a nvValueArrayValue)?
Is this patch the suitable place to add a test?
Updated•18 years ago
|
Assignee: general → nobody
Component: General → XPCOM
OS: Windows XP → All
Product: Mozilla Application Suite → Core
QA Contact: general → xpcom
Hardware: PC → All
Target Milestone: Future → ---
Comment 2•18 years ago
|
||
(In reply to comment #1)
>Attached a patch proposal.
Thanks for the patch, but I don't think this quite does what we were looking for; this bug was filed to make nsUInt32Array.cpp obsolete, and its SetSize changes the count (and clears new items) as well as the checking the capacity.
>Is this patch the suitable place to add a test?
Yes.
| Assignee | ||
Comment 3•18 years ago
|
||
Thanks for your answer Neil, I will take a look at nsUInt32Array.cpp and will submit a new patch if no-one did it before.
| Assignee | ||
Comment 4•18 years ago
|
||
Here is a new patch.
Attachment #273157 -
Attachment is obsolete: true
| Assignee | ||
Comment 5•18 years ago
|
||
This is my test program output
Comment 6•18 years ago
|
||
OK, so the next step is to find someone to review your patch. dougt@meer.net benjamin@smedbergs.us and darin@meer.net are listed on the module owners document as current peers although benjamin looks to be the most active.
Assignee: nobody → regis.caspar+bz
| Assignee | ||
Comment 7•18 years ago
|
||
Comment on attachment 274274 [details] [diff] [review]
proposed patch + new test for nsValueArray
Thanks for the directions Neil :)
Attachment #274274 -
Flags: review?(benjamin)
Comment 8•18 years ago
|
||
What are the clients of nsValueArray, and why do we want to add this API to it? I would prefer that all new consumers use nsTArray<PRInt32> or something like that.
Comment 9•18 years ago
|
||
guess this'd be for bug 250811, which predates nsTArray
Comment 10•18 years ago
|
||
Comment on attachment 274274 [details] [diff] [review]
proposed patch + new test for nsValueArray
I would prefer not to extend this class any more, but switch clients to nsTArray (unless there is a compelling reason I haven't heard yet).
Attachment #274274 -
Flags: review?(benjamin) → review-
| Assignee | ||
Comment 11•18 years ago
|
||
OK (I don't know the background history of that bug..)
-> Removing the "helpwanted" for now.
Whiteboard: helpwanted
Updated•18 years ago
|
Status: NEW → RESOLVED
Closed: 18 years ago
Resolution: --- → WONTFIX
You need to log in
before you can comment on or make changes to this bug.
Description
•