Revert 6f68e52 and fix the gcc2 build via template.
* Instead of forcing the hash-table to use a copy of the key, introduce and use TypeOperation template to avoid taking a reference of a reference type (which gcc2 doesn't allow).
This commit is contained in:
@@ -13,6 +13,9 @@
|
||||
#ifdef _KERNEL_MODE
|
||||
# include <KernelExport.h>
|
||||
# include <util/kernel_cpp.h>
|
||||
# include <util/TypeOperation.h>
|
||||
#else
|
||||
# include <TypeOperation.h>
|
||||
#endif
|
||||
|
||||
|
||||
@@ -136,7 +139,7 @@ public:
|
||||
return fItemCount;
|
||||
}
|
||||
|
||||
ValueType* Lookup(const KeyType& key) const
|
||||
ValueType* Lookup(typename TypeOperation<KeyType>::ConstRefT key) const
|
||||
{
|
||||
if (fTableSize == 0)
|
||||
return NULL;
|
||||
@@ -364,7 +367,7 @@ public:
|
||||
return Iterator(this);
|
||||
}
|
||||
|
||||
Iterator GetIterator(const KeyType& key) const
|
||||
Iterator GetIterator(typename TypeOperation<KeyType>::ConstRefT key) const
|
||||
{
|
||||
if (fTableSize == 0)
|
||||
return Iterator(this, fTableSize, NULL);
|
||||
|
||||
Reference in New Issue
Block a user