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

Re: g++-3.2 problem



W. Paul Mills wrote:
> The following program compiles with g++-2.95, but not with g++-3.2. Any 
> idea why? Use old style "#include <iostream.h>" and it works in 3.2.
> #include <iostream>
>   cout << "Hello World!\n";

You need to get an new C++ book that covers the new C++ syntax.  Look
up 'namespaces'.  The previous iostreams are now moved into the 'std'
namespace.  Try changing to this instead.

  std::cout << "Hello World!\n";

Bob

Attachment: pgpGbliDbnSws.pgp
Description: PGP signature


Reply to: