Add templated find overload for compatible keys.

[SVN r58405]
This commit is contained in:
Daniel James committed 2009-12-15 22:53:33 +00:00
1 parent 493f905598
commit b99382b551
7 files changed
+287

No files matched your search

+19
View File
@@ -395,6 +395,15 @@ namespace boost
return const_iterator(table_.find(k));
}
template <class CompatibleKey, class CompatibleHash,
class CompatiblePredicate>
const_iterator find(
CompatibleKey const& k,
CompatibleHash const& hash,
CompatiblePredicate const& eq) const
{
return iterator(table_.find(k, hash, eq));
}
size_type count(const key_type& k) const
{
return table_.count(k);
@@ -874,6 +883,16 @@ namespace boost
return const_iterator(table_.find(k));
}
template <class CompatibleKey, class CompatibleHash,
class CompatiblePredicate>
const_iterator find(
CompatibleKey const& k,
CompatibleHash const& hash,
CompatiblePredicate const& eq) const
{
return iterator(table_.find(k, hash, eq));
}
size_type count(const key_type& k) const
{
return table_.count(k);