Re: return'ing a struct and trap representations

2006-09-24 Thread Paul Eggert
>> Should be: for integer and pointer types there are _no_ "trap >> representations". > > I don't think that is guaranteed by C99. That's correct. As I recall, only unsigned char objects are guaranteed to be free of trap representations. > Certainly the practical value of this for gnulib is que

Re: return'ing a struct and trap representations

2006-09-22 Thread Ralf Wildenhues
Hello Bruno, * Bruno Haible wrote on Fri, Sep 22, 2006 at 05:31:08PM CEST: > > > However, for integer and pointer types there are "trap representations". > > Should be: for integer and pointer types there are _no_ "trap > representations". I don't think that is guaranteed by C99. Quoting 6.2.6

Re: return'ing a struct and trap representations

2006-09-22 Thread Bruno Haible
> > However, for integer and pointer types there are "trap representations". Should be: for integer and pointer types there are _no_ "trap representations". > all potentially uninitialized variables are size_t ones, thus > unsigned integer types; these do not have trap representations. Yes, it d

Re: return'ing a struct and trap representations

2006-09-22 Thread Ralf Wildenhues
Hello Bruno, * Bruno Haible wrote on Fri, Sep 22, 2006 at 03:34:14PM CEST: > > > GCC 4.0.3 and newer (with `-Wall -Werror -fno-builtin' on a GNU/Linux > > x86_64 system) errors out at some of the list implementation > > "constructor" functions: > > | gl_array_list.c: In function ‘gl_array_iterato

Re: return'ing a struct and trap representations

2006-09-22 Thread Bruno Haible
Hello Ralf, > GCC 4.0.3 and newer (with `-Wall -Werror -fno-builtin' on a GNU/Linux > x86_64 system) errors out at some of the list implementation > "constructor" functions: > | gl_array_list.c: In function ‘gl_array_iterator’: > | gl_array_list.c:398: warning: ‘result.j’ is used uninitialized in

return'ing a struct and trap representations

2006-09-21 Thread Ralf Wildenhues
Hello Bruno, all, GCC 4.0.3 and newer (with `-Wall -Werror -fno-builtin' on a GNU/Linux x86_64 system) errors out at some of the list implementation "constructor" functions: | gl_array_list.c: In function ‘gl_array_iterator’: | gl_array_list.c:398: warning: ‘result.j’ is used uninitialized in this