CC help

Martin v. Loewis martin@loewis.home.cs.tu-berlin.de
Mon Jun 19 11:38:00 GMT 2000


> Hello.  I am currently using your C++ compiler, and I have a few questions

Thanks for your bug report. Please have a look at

http://www.gnu.org/software/gcc/bugs.html

for bug reporting instructions

> I cannot find the answers to: first, how do i use namespaces?  I am trying
> to use namespace std and the compiler doesn't recognize the 
>  
> using namespace std
>
> command.

What do you mean, it doesn't recognize the command? Maybe it's because
you forgot the semicolon after std?

> Second, how do I declare strings?  I have included the header
> file <string.h> but the compiler will not recognize the declaration 
>  
> string myString;

In C++, std::string is not defined in <string.h>, but in <string>.

Please read a C++ book for details.

Regards,
Martin


More information about the Gcc-bugs mailing list