title: Why including <string.h> in .cpp file causes compilation errors (while including it .h file is ok)
body: <p>I have a strange compilation error when using:</p>
  
  <pre><code>#include &lt;string.h&gt;
  </code></pre>
  
  <p>in .cpp file:</p>
  
  <pre><code>/usr/include/string.h:47:8: error: ‘size_t’ has not been declared
          size_t __n) __THROW __nonnull ((1, 2));
          ^
  /usr/include/string.h:50:56: error: ‘size_t’ has not been declared
   extern void *memmove (void *__dest, const void *__src, size_t __n)
                                                          ^
  /usr/include/string.h:59:18: error: ‘size_t’ has not been declared
           int __c, size_t __n)
                    ^
  /usr/include/string.h:66:42: error: ‘size_t’ has not been declared
   extern void *memset (void *__s, int __c, size_t __n) __THROW __nonnull ((1));    /usr/include/string.h:47:8: error: ‘size_t’ has not been declared
          size_t __n) __THROW __nonnull ((1, 2));
          ^
  /usr/include/string.h:50:56: error: ‘size_t’ has not been declared
   extern void *memmove (void *__dest, const void *__src, size_t __n)
                                                          ^
  /usr/include/string.h:59:18: error: ‘size_t’ has not been declared
           int __c, size_t __n)
                    ^
  /usr/include/string.h:66:42: error: ‘size_t’ has not been declared
   extern void *memset (void *__s, int __c, size_t __n) __THROW __nonnull ((1));
                                            ^
  /usr/include/string.h:69:56: error: ‘size_t’ has not been declared
   extern int memcmp (const void *__s1, const void *__s2, size_t __n)
                                            ^
  /usr/include/string.h:69:56: error: ‘size_t’ has not been declared
   extern int memcmp (const void *__s1, const void *__s2, size_t __n)
  </code></pre>
  
  <p>while putting the same line code in .h file, does not give any errors.</p>
  
  <p>I'm confused, what is the problem ?</p>