Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

nsHashtable is DEPRECATED!

1 view
Skip to first unread message

Alec Flett

unread,
May 15, 2003, 2:26:57 PM5/15/03
to mozill...@mozilla.org, mozilla-...@mozilla.org
I don't think a formal announcement ever went out about this:

As of a few days ago, nsHashtable is officially deprecated and
nsTHashtable is the "new" hashtable implementation. nsTHashtable is more
"heap friendly" and in general requires a much smaller footprint than
nsHashtable.

The only hashtables you should be using in the mozilla codebase going
forward are:
- nsTHashtable
- pldhash
- plhashtable (from NSPR)

For more info on nsTHashtable and friends, please see Benjamin
Smedberg's excellent hashtable guide:
http://www.mozilla.org/projects/xpcom/hashtable-guide.html

(this document is a work-in-progress of course)

There are no plans to make a tree-wide sweep of nsHashtable to convert
it to nsTHashtable, there are simply too many of them. When he has time,
Ben has said he may go and convert some consumers here and there, so
please help out by reviewing code when he requests it. (Thanks Ben!)

Alec


0 new messages