title: Why std::size() is not a member of std in gcc 8.2.0
body: <p>I'm trying to teach myself some C++17.</p>
  
  <p>Why is the compiler throwing an error for the below code snippet?</p>
  
  <pre><code>#include &lt;iostream&gt; 
  #include &lt;vector&gt;
  #include &lt;iterator&gt;
  
  int main() 
  {
      std::vector&lt;int&gt; v = { 3, 1, 4 };
      std::cout &lt;&lt; std::size(v) &lt;&lt; '\n'; 
  
      int a[] = { -5, 10, 15 };
      std::cout &lt;&lt; std::size(a) &lt;&lt; '\n';
  }
  </code></pre>
  
  <p>The compiler throws the following error</p>
  
  <pre><code>manish@Manish-Tummala:~/c_files$ g++ 6.cpp -o - 6.out
  6.cpp: In function ‘int main()’:
  6.cpp:8:23: error: ‘size’ is not a member of ‘std’
       std::cout &lt;&lt; std::size(v) &lt;&lt; '\n';
                         ^~~~
  6.cpp:8:23: note: suggested alternative: ‘size_t’
       std::cout &lt;&lt; std::size(v) &lt;&lt; '\n';
                         ^~~~
                         size_t
  6.cpp:11:23: error: ‘size’ is not a member of ‘std’
       std::cout &lt;&lt; std::size(a) &lt;&lt; '\n';
                         ^~~~
  6.cpp:11:23: note: suggested alternative: ‘size_t’
       std::cout &lt;&lt; std::size(a) &lt;&lt; '\n';
                         ^~~~
                         size_t
  </code></pre>