merged 2.4 branch into the trunk

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@18040 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2002-12-04 14:11:26 +00:00
parent 59a944cb63
commit 2b5f62a0b2
1057 changed files with 37805 additions and 24034 deletions

View File

@@ -62,9 +62,9 @@ protected:
_wxHashTable_NodeBase** dstTable,
BucketFromNode func, ProcessNode proc );
static void** AllocTable( size_t size )
static void** AllocTable( size_t sz )
{
return (void **)calloc(size, sizeof(void*));
return (void **)calloc(sz, sizeof(void*));
}
};
@@ -172,10 +172,10 @@ public: \
const_pointer operator ->() const { return &(m_node->m_value); } \
}; \
\
CLASSNAME( size_type size = 10, const hasher& hfun = hasher(), \
CLASSNAME( size_type sz = 10, const hasher& hfun = hasher(), \
const key_equal& k_eq = key_equal(), \
const key_extractor& k_ex = key_extractor() ) \
: m_tableBuckets( GetNextPrime( size ) ), \
: m_tableBuckets( GetNextPrime( sz ) ), \
m_items( 0 ), \
m_hasher( hfun ), \
m_equals( k_eq ), \
@@ -218,7 +218,12 @@ public: \
\
/* removes all elements from the hash table, but does not */ \
/* shrink it ( perhaps it should ) */ \
void clear() { DeleteNodes( m_tableBuckets, (_wxHashTable_NodeBase**)m_table, DeleteNode ); } \
void clear() \
{ \
DeleteNodes( m_tableBuckets, (_wxHashTable_NodeBase**)m_table, \
DeleteNode ); \
m_items = 0; \
} \
\
size_type size() const { return m_items; } \
size_type max_size() const { return size_type(-1); } \