From: Weiqi Gao Newsgroups: comp.os.msdos.djgpp Subject: Re: djgpp is ansi c++ compliant? Date: Fri, 12 Nov 1999 07:50:19 -0600 Organization: CRL Network Services Lines: 17 Message-ID: <382C1B1B.B5F10ED4@a.crl.com> References: NNTP-Posting-Host: a116003.stl1.as.crl.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Mailer: Mozilla 4.51 [en] (X11; I; Linux 2.2.5-15 i586) X-Accept-Language: en To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Ali Ahmad Siddiqui wrote: > > I am having problems trying to compile code in djgpp that I have written > on my MSVC compiler. It compiles fine on MSVC, but produces errors in > djgpp even though I think I am writing ansi code. For instance if I have > a prototype function in MSVC: "int funTimes(int, int, int)" MSVC takes it > fine, but djgpp thinks this is a bad thing to do and produces errors. > All help in this matter would be very much appreciated "int funTimes(int, int, int)" is not legal C. You need to go "int funTimes(int, int, int);" (notice the semicolon) for the code to compile. You also need to define the function somewhere before the compiled object files will link. -- Weiqi Gao weiqigao AT a DOT crl DOT com