help-gplusplus
[Top][All Lists]
Advanced

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

g++ flag?


From: Abhisek Sinha
Subject: g++ flag?
Date: 13 May 2004 05:25:37 -0700

Hi there,
Earlier compilers used to take the default return type of any function
to be int.
g++, in this case where ther is no return type specified gives error
as
error: ISO C++ forbids declaration of `main' with no type

can this be disabled using any g++ flag in 3.3.3 

It is to be noted that gcc(3.3.2) does not throw any any error even if
there is no return type.
Not even with -ansi and -pedantic flag

Can somebody tell, is gcc not strictly adhering to ISO C++ standard?

Thanks
A


reply via email to

[Prev in Thread] Current Thread [Next in Thread]