From: sl AT psycode DOT com DOT REMOVE_THIS Newsgroups: comp.os.msdos.djgpp Subject: Re: DJGPP/GCC bug found Date: 22 Sep 1998 00:54:19 GMT Organization: http://www.supernews.com, The World's Usenet: Discussions Start Here Lines: 19 Message-ID: References: <6thlos$nc AT news-central DOT tiac DOT net> NNTP-Posting-Host: 205.205.119.128 Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8bit To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk On Sun, 13 Sep 1998 23:55:49, "Martin Ambuhl" wrote: > | In the above example, the compiler complains "return;" is used in a > |case where "main()" is non-void.. But as you can see, it IS declared > |to return void! > > And illegally so. g++ is smart enough to replace your illegal 'void' > with the > _required_ 'int'. It's one thing to complain "main() must return int".. It's a totally other matter when GCC complains of an error _IT_ causes .. What I mean by this is that it makes a modification without telling me about it, therefore the error message which follows only serves to confuse the user.. Not aid them .. Gili