RE: cout function and iostream.h

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

 



try #include <iostream> at the beginning.
I'll look into my streams and see what file is called.
You can't call .h files in C++ like that.
Robert

-----Original Message-----
From: gcc-help-owner@xxxxxxxxxxx [mailto:gcc-help-owner@xxxxxxxxxxx]On
Behalf Of abcd efgh
Sent: Thursday, January 08, 2004 3:21 AM
To: gcc-help@xxxxxxxxxxx
Subject: cout function and iostream.h


Hello,

I am trying to compile a simple "hello world" program:

#include "iostream.h"
int main()
{
  cout << "Hello\n";
}

with the command 

g++ -Wall hello.C -o hello

and I receive the following warning:

"This file includes at least one deprecated or
antiquated header. Please consider using one of the 32
headers found in section 17.4.1.2 of the C++ standard.
Examples include substituting the <X> header for the
<X.h> header for C++ includes, or <sstream> instead of
the deprecated header <strstream.h>. To disable this
warning use -Wno-deprecated."

An executable file is created but it doesn't run.

Is there a new header to obtain the cout function, or
was it replaced ?


Thanks in advance for any help,

Antonio Serra


__________________________________
Do you Yahoo!?
Yahoo! Hotjobs: Enter the "Signing Bonus" Sweepstakes
http://hotjobs.sweepstakes.yahoo.com/signingbonus



[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