title: std::tolower and Visual Studio 2013
body: <p>I try to understand how to use <code>std::tolower</code>...</p>
  
  <pre><code>#include &lt;iostream&gt;
  #include &lt;string&gt;
  #include &lt;algorithm&gt;
  #include &lt;locale&gt;
  
  int main()
  {
      std::string test = "Hello World";
      std::locale loc;
      for (auto &amp;c : test)
      {
          c = std::tolower(c, loc);
      }
  
      std::transform(test.begin(), test.end(), test.begin(), ::tolower); // 1) OK
      std::transform(test.begin(), test.end(), test.begin(), std::tolower); // 2) Cryptic compile error
      std::transform(test.begin(), test.end(), test.begin(), static_cast&lt;int(*)(int)&gt;(std::tolower)); // 3) Cryptic compile error. Seems OK with other compilers though
  
      return 0;
  }
  </code></pre>
  
  <p>So:</p>
  
  <ol>
  <li>Why <code>::tolower</code> version is working? </li>
  <li>Why <code>std::tolower</code> is not working in std::transform? </li>
  <li>What <code>static_cast&lt;int(*)(int)&gt;(std::tolower))</code> really is trying to do? Why
  does it work with GCC and not with Visual Studio 2013?</li>
  <li>How could I use <code>std::lower</code> in std::transform with Visual Studio 2013 then?</li>
  </ol>