Re: error: 'string' undeclared (first use in this function)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



"vinod" <vinod.nanjaiah@xxxxxxxxx> writes:

> Hi all ~
> I have #include <string.h> , but why am I still can't declare string ?
>
>
> When I compile my code ,show the error msg as follows :
> root@acer:~/probeServer# gcc probec.c -o probec -lm -lpthread
> probec.c:1:18: error: string: No such file or directory

<string> is not found.  <string> is a C++ header.  If you want C++,
compile with g++, not gcc.

Ian

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux