2004-04-08, 11:50 PM
when i try to compile this simple c++ source
Code:
#include<iostream.h>
void main()
{
cout<<"HELLO WORLD";
}
with
Code:
[seeno@localhost seeno]$ gcc helloworld.cpp
i get this
Code:
In file included from /usr/include/c++/3.2.2/backward/iostream.h:31,
from helloworld.cpp:1:
/usr/include/c++/3.2.2/backward/backward_warning.h:32:2: warning: #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.
helloworld.cpp:3: `main' must return `int'
and when i compile with the -Wno-deprecated option, i just get this
Code:
[seeno@localhost seeno]$ gcc -Wno-deprecated helloworld.cpp
helloworld.cpp:3: `main' must return `int'