title: error: no matching function for call to 'std::map
body: <pre><code>typedef struct {
      string strDatabaseName;
      set &lt;string, greater&lt;string&gt; &gt; setDBAccName;
  } UserDBAInfo_t;
  
  typedef struct {
      map&lt;int, UserDBAInfo_t &gt; mapUserDBAInfo;
  } UserDBInfo_t;
  
  typedef set&lt;string, greater&lt;string&gt; &gt; setNames_t;
  
  int main( int argc, char * argv[] )
  {
      ...
      map&lt;string, UserDBInfo_t &gt; mapHRUserDBInfo;
  
      UserDBInfo_t structUserDBInfo;
      UserDBAInfo_t structUserDBAInfo;
  
      structUserDBAInfo.strDatabaseName = strDatabaseName;
      structUserDBAInfo.setDBAccName.insert(strDBAccName);
  
      structUserDBInfo.mapUserDBAInfo.insert(nDatabaseID, structUserDBAInfo);
  
      mapHRUserDBInfo.insert(make_pair(strSabun, structUserDBInfo));   &lt;--- compile error here
  
      ...
  
  }
  </code></pre>
  
  <p>When I compile it, I got error message.</p>
  
  <blockquote>
    <p>main.cpp:2778: error: no matching function for call to 'std::map&lt;int, UserDBAInfo_t, std::less&lt;int>, std::allocator&lt;std::pair&lt;const int, UserDBAInfo_t> > >::insert(int&amp;, UserDBAInfo_t&amp;)'
    /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../include/c++/4.1.2/bits/stl_map.h:395: note: candidates are: std::pair&lt;typename std::_Rb_tree&lt;_Key, std::pair&lt;const _Key, _Tp>, std::_Select1st&lt;std::pair&lt;const _Key, _Tp> >, _Compare, typename _Alloc::rebind&lt;std::pair&lt;const _Key, _Tp> >::other>::iterator, bool> std::map&lt;_Key, _Tp, _Compare, _Alloc>::insert(const std::pair&lt;const _Key, _Tp>&amp;) [with _Key = int, _Tp = UserDBAInfo_t, _Compare = std::less&lt;int>, _Alloc = std::allocator&lt;std::pair&lt;const int, UserDBAInfo_t> >]
    /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../include/c++/4.1.2/bits/stl_map.h:419: note:                 typename std::_Rb_tree&lt;_Key, std::pair&lt;const _Key, _Tp>, std::_Select1st&lt;std::pair&lt;const _Key, _Tp> >, _Compare, typename _Alloc::rebind&lt;std::pair&lt;const _Key, _Tp> >::other>::iterator std::map&lt;_Key, _Tp, _Compare, _Alloc>::insert(typename std::_Rb_tree&lt;_Key, std::pair&lt;const _Key, _Tp>, std::_Select1st&lt;std::pair&lt;const _Key, _Tp> >, _Compare, typename _Alloc::rebind&lt;std::pair&lt;const _Key, _Tp> >::other>::iterator, const std::pair&lt;const _Key, _Tp>&amp;) [with _Key = int, _Tp = UserDBAInfo_t, _Compare = std::less&lt;int>, _Alloc = std::allocator&lt;std::pair&lt;const int, UserDBAInfo_t> >]</p>
  </blockquote>
  
  <p>What might be wrong?</p>