title: std::set::iterator conversion error
body: <p>I am using an <code>std::set</code> to hold members of type <code>Board</code>, and I want to iterate over the set to do comparisons that will not work with the find method as different criteria will be used for sorting verses locating.</p>
  
  <pre><code>1&gt;c:\...\project.cpp(1140): error C2440: 'initializing' : cannot convert from 'std::_Tree_const_iterator&lt;_Mytree&gt;' to 'std::_Tree_const_iterator&lt;_Mytree&gt;'
  1&gt;          with
  1&gt;          [
  1&gt;              _Mytree=std::_Tree_val&lt;std::_Tset_traits&lt;Board,std::greater&lt;Board&gt;,std::allocator&lt;Board&gt;,false&gt;&gt;
  1&gt;          ]
  1&gt;          and
  1&gt;          [
  1&gt;              _Mytree=std::_Tree_val&lt;std::_Tset_traits&lt;Board,std::less&lt;Board&gt;,std::allocator&lt;Board&gt;,false&gt;&gt;
  1&gt;          ]
  1&gt;          No constructor could take the source type, or constructor overload resolution was ambiguous
  </code></pre>
  
  <p>the thing is the iterator should not be const. the method is not const, the set is created local to the method, and I do not preface the iterator as const.</p>
  
  <pre><code>Thing::Thing thisFunction(int action){
      // snip 
      set&lt;Board, less&lt;Board&gt;&gt; openSet;
      // snip 
      for(set&lt;Board&gt;::iterator ii = openSet.begin();  // line 1140
          ii != openSet.end(); ii++){
              // snip 
      }
  </code></pre>
  
  <p>this does not make direct sense as the iterator is not declared const so it should not be trying to even consider const.</p>
  
  <p>separately why is the compiler talking about a <code>std::_tree</code> when I am using a <code>std::set</code></p>