Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: 3.1.0-test3: gcc -ansi -pedantic



On Tue, 19 Nov 1996, Thorsten Meinecke wrote:

> Hello, did anyone bother before to build zsh with gcc -ansi -pedantic?
> 
> It looks like some of the module-related changes aren't ANSI/ISO C,
> and from some of the older stuff it elicits warnings about variable
> sized arrays and conversions w/o cast as well.  Furthermore, there's
> trouble in module.c, because gcc says ANSI forbids assignment between
> function pointer and `void *'.  Most serious:
> 
>   ../Src> gcc -c -I.. -I. -I. -DHAVE_CONFIG_H -Wall -Wno-implicit \
>   -Wmissing-prototypes -g -ansi -pedantic  zle_main.c
>   zle_main.c: In function `zleread':
>   zle_main.c:439: warning: ANSI C forbids use of conditional expressions as lvalues
>   zle_main.c: In function `unbindzlefunc':
>   zle_main.c:1257: initializer element for `keybindlist[0]' is not computable at load time
>   zle_main.c:1257: initializer element for `keybindlist[1]' is not computable at load time
>   make: *** [zle_main.o] Error 1
> 

I don't use gcc, but my compiler did give the same errors. I just had no
time to send a patch :-(


> I can offer fixes for the error (and the warnings) in the zle_*
> module-related code, by introducing yet another level of indirection
> to both underlying problems.
>

Yes, I was ready to propose the same ;)
thanks

greetings
 
-------------------------------------------------------------------------
Andrej Borsenkow 		Fax:   +7 (095) 252 01 05
SNI ITS Moscow			Tel:   +7 (095) 252 13 88

NERV:  borsenkow.msk		E-Mail: borsenkow.msk@xxxxxx
-------------------------------------------------------------------------




Messages sorted by: Reverse Date, Date, Thread, Author