patch for problem with va-ppc.h included with egcs and  gcc-2.95.2
    Franz Sirl 
    Franz.Sirl-kernel at lauterbach.com
       
    Tue Nov 30 21:58:19 EST 1999
    
    
  
At 07:00 30.11.99 , Jason Kim wrote:
>Agreed, ssh2 code isn't necessarily the cleanest in the world, but then again
>the varargs situation in PPC world is a bit peculiar.
>
>
>typedef struct A {
>   char foo;
>   char *bar;
>} B[1], C[1];
>
>typedef C D;
>
>
>void tst(D d1)
>{
>   D d2;
>   d1 = d2; // this is legal
>   // d2 = d1; // this is not
>}
>
>declaring arrays of fixed size seems a bit strange for a type which will 
>be used
>by user code, since it makes d1 and d2 be different types sometimes. Not to
>mention, having struct _va_list_tag  AS va_list seem to fix the problems 
>neatly.
>
>Is there a technical reason for keeping va_list as an array of 1 element?
>(instead of just a single element??)
1. this behaviour is mandated by the ABI
2. it nicely spots a common programming error
I see nothing peculiar about it :-).
BTW, it would be nice if you could fix your spam filter, my last message 
was rejected, even though there was no faked IP in it.
Franz.
** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
    
    
More information about the Linuxppc-dev
mailing list