From: Jason Green Newsgroups: comp.os.msdos.djgpp Subject: Re: Warning : if (x=y) Date: Wed, 13 Sep 2000 00:48:21 +0100 Organization: Customer of Energis Squared Lines: 20 Message-ID: References: NNTP-Posting-Host: modem-96.dexfenfluramine.dialup.pol.co.uk Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: newsg2.svr.pol.co.uk 968802555 8486 62.136.89.224 (12 Sep 2000 23:49:15 GMT) NNTP-Posting-Date: 12 Sep 2000 23:49:15 GMT X-Complaints-To: abuse AT theplanet DOT net X-Newsreader: Forte Agent 1.7/32.534 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Andris Pavenis wrote: > With gcc-2.95.2 -fpedantic-errors is default for C++ ... Unless you compile the following as C++ code: int main(void) { char s1[4], s2[4] = "foo"; s1 = s2; /* illegal */ return 0; } I don't know if this is bug or feature. The gcc docs don't say much about -pedantic-errors being the default. I suspect only the diagnostics made compulsory by the C++ standard are on by default, others require -pedantic or -pedantic-errors.