nsTDeque data structure proposal

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

nsTDeque data structure proposal

Darin Fisher-2
Like nsTArray, I'd like to add a nsTDeque class to xpcom/glue/.
Here's a proposed API:
http://wiki.mozilla.org/Class:nsTDeque

A deque is an efficient datastructure for representing a stack or a
queue.  There's a few places in the tree where I want to use this to
either replace nsDeque or hand-rolled queue implementations (e.g.,
nsEventQueue).

Comments?

-Darin
_______________________________________________
dev-planning mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-planning
Reply | Threaded
Open this post in threaded view
|

Re: nsTDeque data structure proposal

Darin Fisher-2
I meant to send this to dev-platform instead of dev-planning.  Please
follow-up on dev-platform.

Thanks!
-Darin


On 6/15/06, Darin Fisher <[hidden email]> wrote:

> Like nsTArray, I'd like to add a nsTDeque class to xpcom/glue/.
> Here's a proposed API:
> http://wiki.mozilla.org/Class:nsTDeque
>
> A deque is an efficient datastructure for representing a stack or a
> queue.  There's a few places in the tree where I want to use this to
> either replace nsDeque or hand-rolled queue implementations (e.g.,
> nsEventQueue).
>
> Comments?
>
> -Darin
>
_______________________________________________
dev-planning mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-planning
Reply | Threaded
Open this post in threaded view
|

Re: nsTDeque data structure proposal

Christian Biesinger
In reply to this post by Darin Fisher-2
Darin Fisher wrote:
> Like nsTArray, I'd like to add a nsTDeque class to xpcom/glue/.

So is reimplementing the STL one piece at a time really a good use of
time? Put differently, can we consider using the STL directly these days?


--
All the world's a stage,
And all the men and women merely players:
They have their exits and their entrances;
And one man in his time plays many parts, [...]     --W. Shakespeare
_______________________________________________
dev-planning mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-planning