dunque...
ho scritto un programmino stupido stupido
e compilando con devcppcodice:#include<iostream.h> int i_max(int x, int y) { return (x > y) ? x : y; } double d_max(double x, double y) { return (x > y) ? x : y; } int main() { int a, b = 4; double c = 4.0, d; a = i_max(3, b); d = d_max(3.6, c); cout << a << '\t' << b << '\n'; system("pause"); }
ricevo un warning fastidioso...
se invece di includere iostream.h includo iostream (senza il .h) il warning sparisce, in compenso però ho un errore sulla riga del cout...1 C:\Programmi\Dev-Cpp\include\c++\3.3.1\backward\iostream.h:31, from C:\Documents and Settings\root\Desktop\C++\4.2 3.cpp In file included from C:/Programmi/Dev-Cpp/include/c++/3.3.1/backward/iostream.h:31, from C:/Documents and Settings/root/Desktop/C++/4.2 3.cpp
2 C:\Programmi\Dev-Cpp\include\c++\3.3.1\backward\backward_warning.h: 32 #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.
come risolvo??