[ccache] Compiler warnings in ccache 3.2.3

Tom Lane tgl at sss.pgh.pa.us
Mon Aug 17 21:25:53 UTC 2015

Joel Rosdahl <joel at rosdahl.net> writes:
>> I got a few warnings about assignments of pointers to "bool" values. I
>> think these are legitimate gripes, because on platforms where bool is only
>> a byte wide, the net effect will be to assign the pointer's low-order byte
>> to the bool.

> Well, as I interpret the C99 standard, bool from stdbool.h (AKA _Bool) is
> guaranteed to only contain 1 or 0: ...

> However, ccache's system.h has fallback code on systems that don't have
> stdbool.h and then a bool can be typedef-ed to be a signed char, which is
> something I didn't think of when writing the code in question. (I guess you
> are on such an "antique" non-C99 system?)

Ah, right, that explains why I only saw the warnings on a pretty old box.

			regards, tom lane

More information about the ccache mailing list