summaryrefslogtreecommitdiffstats
path: root/src/symbolmap.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/symbolmap.h')
-rw-r--r--src/symbolmap.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/symbolmap.h b/src/symbolmap.h
index 0f837d4..a277846 100644
--- a/src/symbolmap.h
+++ b/src/symbolmap.h
@@ -36,15 +36,15 @@ class SymbolMap
using const_iterator = typename Map::const_iterator;
//! Add a symbol \a def into the map under key \a name
- void add(const char *name,Ptr def)
+ void add(const QCString &name,Ptr def)
{
- m_map.insert({std::string(name),def});
+ m_map.insert({name.str(),def});
}
//! Remove a symbol \a def from the map that was stored under key \a name
- void remove(const char *name,Ptr def)
+ void remove(const QCString &name,Ptr def)
{
- auto range = find(name);
+ auto range = find(name.str());
for (auto it=range.first; it!=range.second; )
{
if (it->second==def) it = m_map.erase(it); else ++it;
@@ -53,16 +53,16 @@ class SymbolMap
//! Find the list of symbols stored under key \a name
//! Returns a pair of iterators pointing to the start and end of the range of matching symbols
- std::pair<const_iterator,const_iterator> find(const char *name) const
+ std::pair<const_iterator,const_iterator> find(const QCString &name) const
{
- return m_map.equal_range(name ? name : "");
+ return m_map.equal_range(name.str());
}
//! Find the list of symbols stored under key \a name
//! Returns a pair of iterators pointing to the start and end of the range of matching symbols
- std::pair<iterator,iterator> find(const char *name)
+ std::pair<iterator,iterator> find(const QCString &name)
{
- return m_map.equal_range(name ? name : "");
+ return m_map.equal_range(name.str());
}
iterator begin() { return m_map.begin(); }