> -----Original Message-----
> From: pgsql-hackers-owner@postgresql.org [mailto:pgsql-hackers-
> owner@postgresql.org] On Behalf Of Bernd Helmle
> Sent: Thursday, July 16, 2009 8:47 AM
> To: Grzegorz Jaskiewicz
> Cc: pgsql-hackers Hackers
> Subject: Re: [HACKERS] boolean in C
>
> --On 16. Juli 2009 13:32:03 +0100 Grzegorz Jaskiewicz
> <gj@pointblue.com.pl>
> wrote:
>
> > oh, another thing.
> > stdbool is C99 standard feature. Not gcc extension.
>
> There might be compiler versions out there which claims to be C99 but
> do
> not provide full compliant include headers. SUN Studio 12 at least has
> the
> following in its documentation, as a quick research brings up:
>
> "Though the compiler defaults to supporting the features of C99 listed
> below, standard headers provided by the Solaris software in
> /usr/include do
> not yet conform with the 1999 ISO/IEC C standard"
It's more or less a generic problem. There is only a handful of fully
functional C99 compilers[0], and all the others have "Some c99 features"
to one degree or another.
Microsoft's compiler is particularly abysmal, but then again, they have
no claims of C99 compliance so there is nothing to complain about there.
Those few features that they do implement are implemented in a
non-standard way.
GCC is also only partially compliant[1].
I believe that the Dinkum library is the only certified C99 standard
library[2] as well.
[0] see: http://www.peren.com/pages/branding_set.htm
[1] see: http://gcc.gnu.org/c99status.html
[2] see: http://www.dinkumware.com/manuals/
I don't think that a product (that is expected to run on as many
platforms as PostgreSQL is expected to run on) is even possible to write
in C99 code because there are not enough compliant compilers available.
IMO-YMMV