Re: Ada type in binding for C99 bool

2009-09-22 Thread Joseph S. Myers
On Tue, 22 Sep 2009, Joel Sherrill wrote: > It appears to be unsigned char or at least sizeof(bool)=1 > on the architectures I tried this test program on. The size is determined by BOOL_TYPE_SIZE (and is not 1 byte for powerpc-darwin). -- Joseph S. Myers jos...@codesourcery.com

Re: Ada type in binding for C99 bool

2009-09-22 Thread Florian Weimer
* Joel Sherrill: >> Whatever the answer is, it should be used to define Interfaces.C.Bool. >> (I don't know what GCC's options for representing _Bool are, sorry.) > It appears to be unsigned char or at least sizeof(bool)=1 > on the architectures I tried this test program on. That's only half of

Re: Ada type in binding for C99 bool

2009-09-22 Thread Gabriel Dos Reis
On Tue, Sep 22, 2009 at 12:54 PM, Joel Sherrill wrote: > Florian Weimer wrote: >> >> * Joel Sherrill: >> >> >>> >>> What is the proper type to use in an Ada binding >>> for a C method that returns a C99 bool? >>> >> >> Whatever the answer is, it should be used to define Interfaces.C.Bool. >> (I do

Re: Ada type in binding for C99 bool

2009-09-22 Thread Joel Sherrill
Florian Weimer wrote: * Joel Sherrill: What is the proper type to use in an Ada binding for a C method that returns a C99 bool? Whatever the answer is, it should be used to define Interfaces.C.Bool. (I don't know what GCC's options for representing _Bool are, sorry.) It appears t

Re: Ada type in binding for C99 bool

2009-09-22 Thread Florian Weimer
* Joel Sherrill: > What is the proper type to use in an Ada binding > for a C method that returns a C99 bool? Whatever the answer is, it should be used to define Interfaces.C.Bool. (I don't know what GCC's options for representing _Bool are, sorry.)

Ada type in binding for C99 bool

2009-09-21 Thread Joel Sherrill
Hi, What is the proper type to use in an Ada binding for a C method that returns a C99 bool? This appears to be an issue in s-stchop-rtems.adb where it binds to the C routine: bool rtems_stack_checker_is_blown( void ) Thanks. -- Joel Sherrill, Ph.D. Director of Research & Developm