[Raw Msg Headers][Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: pre3



I just got back from the seas...

On Tue, Jul 20, 2004 at 06:32:13PM +0200, Tomasz Nowak wrote:
>   Declaration of variable can not be in if{ }

As Prophets K and R defined the C language, the declarations
must all be in the start of the block, they can not FOLLOW
statements that are not declarations.

The ANSI (as of 1990 and 1994) version of the C language does
follow the same.

Now C++ had different ideas..  and C9x/C99 standard got the declarators
spread all over the place.

My default compiler (gcc-3.4.0) follows by default the C99-ish line.
Apparently I can't get that mode off by "gcc -ansi" either...
Ah, "-pedantic" reports it:
  policytest.c:1811: warning: ISO C90 forbids mixed declarations and code

Unfortunately the thing is buried under tons of other semi-meaningless
reports, like:  warning: ISO C90 does not support `long long'
so compiling with  -pedantic-errors  is out of the question :-(

> Tomasz Nowak 18:28 ):
> 
> TN> Eugene Crosser 14:41 ):
> EC>> Just a quick report that .57.pre3 works fine here since Wednesday.
> 
> TN>   I have compilation error:
> 
> TN> policytest.c: In function `pt_mailfrom':
> TN> policytest.c:1810: parse error before `int'
> TN> make[1]: *** [policytest.o] Error 1
> TN> make[1]: Leaving directory
> TN> `/usr/src/triger/sr3/zmailer-2.99.57.pre3/smtpserver'
> TN> make: *** [all] Error 1
> 
> TN> # gcc -v
> TN> Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/2.96/specs
> TN> gcc version 2.96 20000731 (Red Hat Linux 7.1 2.96-98)
> 
> TN> Pozdrawiam.
> Pozdrawiam.
> -- 
> Tomasz Nowak     TRIGER - Systemy Komputerowe   http://www.triger.com.pl

-- 
/Matti Aarnio	<mea@nic.funet.fi>
-
To unsubscribe from this list: send the line "unsubscribe zmailer" in
the body of a message to majordomo@nic.funet.fi