This is the mail archive of the
gsl-discuss@sources.redhat.com
mailing list for the GSL project.
Re: gsl and gcc -Wconversion
- From: Jerome BENOIT <jgmbenoit at wanadoo dot fr>
- To: Olivier Andrieu <oliv__a at users dot sourceforge dot net>
- Cc: gsl-discuss at sources dot redhat dot com
- Date: Tue, 11 Jan 2005 11:21:31 +0000
- Subject: Re: gsl and gcc -Wconversion
- Organization: none
- References: <41E3A76D.9060403@wanadoo.fr> <20050111.113417.74751138.oandrieu@nerim.net>
- Reply-to: jgmbenoit at wanadoo dot fr
Thanks for the quick reply.
Olivier Andrieu wrote:
> Jerome BENOIT [Tue, 11 Jan 2005]:
> Hello List,
>
> recently I add compilation option as it is explained in the GSL Manual to build one of my stuff:
> I have noticed that the option -Wconversion (gcc) produces the warning message
>
> warning: passing arg 4 of `gsl_matrix_char_set' with different width due to prototype
>
> when the fourth is an expected (const char).
>
> The attached program does reproduce this warning with different gcc compiler (gcc 2.95, gcc-3.[234])
> on my Debian (Sarge) Pentium 4M box (i686).
>
> Does I miss something ?
Character constants (in simple quotes, like 'A') are of type int in C.
Indeed !
But what about ((const char)(1)) ?
Otherwise, is there a work around (I would like to use the option -Werror) ?
Thanks,
Jerome