title: find_if() returns unexpected iterator type in const function
body: <p>The following is a distilled version of some code that produces the following error with g++ 4.8:</p>
  
  <pre><code>x.cpp: In member function ‘void Container::find() const’:
  x.cpp:11:71: error: 
  conversion from ‘__gnu_cxx::__normal_iterator&lt;const Element*, std::vector&lt;Element&gt; &gt;’ to non-scalar type ‘std::vector&lt;Element&gt;::iterator {aka __gnu_cxx::__normal_iterator&lt;Element*, std::vector&lt;Element&gt; &gt;}’ requested vector&lt;Element&gt;::iterator it = find_if(v.begin(), v.end(), f);
  </code></pre>
  
  <p>And here is the code:</p>
  
  <pre><code>#include &lt;algorithm&gt;
  #include &lt;vector&gt;
  using namespace std;
  
  struct Element{};
  struct Functor{ bool operator()(const Element &amp; ){return false;}; };
  struct Container{
     vector&lt;Element&gt; v;
     void find() const {
        Functor f;
        vector&lt;Element&gt;::iterator it = find_if(v.begin(), v.end(), f);
     }
  };
  int main() { return 0; }
  </code></pre>
  
  <p>The error disappears after removing the const qualifier on the <code>find()</code> function.
  What is the reason for the error? References to standard are encouraged.
  The logic of the predicate etc. have been removed to focus on the problem of interest.
  clang 3.4 produces similar results.</p>