[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: AC_HEADER_STDBOOL fails with clang

From: Paul Eggert
Subject: Re: AC_HEADER_STDBOOL fails with clang
Date: Mon, 23 Aug 2010 10:20:31 -0700
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv: Gecko/20100713 Thunderbird/3.0.6

On 08/23/10 09:36, Eric Blake wrote:
> gcc, where we know that the extension is supported, to make sure we
> don't introduce a future regression that could have been detected by gcc
> (and in case the AIX compiler is ever fixed).

Well, perhaps "gratuitous" was not the right word, but there is no need
for GCC to compile that code, as GCC doesn't have the bug in question.
GCC compiles that code only for software-engineering purposes, and
(as this discussion suggests) those purposes are not being well supported,
as the code has been buggy for years (-1 versus 0) and nobody has noticed.

Since the bug has not been detected for years,
I hope that the AIX bug has been fixed, and that nobody uses the old,
buggy AIX compilers any more, and that we can remove the test entirely
without anybody caring.  Perhaps that would be the simplest fix.  If I'm
wrong, we will discover that eventually, and we can reinstate the fix.
(I no longer have access to AIX compilers, so I can't test my guess.)

For reference, the discussion that reported the bugs is rooted here:
This bug was reported against AIX 5.3, and IBM will continue to support
5.3 until next year (see 
so perhaps someone who has access to an old 5.3 box can tell us whether
the bug still exists.  If the bug still exists, the following program
will fail on a 64-bit host:

#include <stdbool.h>
#include <assert.h>
int main (void) {
  char digs[10];
  assert (&(digs + 5)[-2 + (bool) 1] == &digs[4]);
  return 0;

reply via email to

[Prev in Thread] Current Thread [Next in Thread]