Mercurial > gnulib
changeset 6345:5abccb682fc6
* stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
promotes to int, not unsigned int, to catch the AIX 5.3
compiler bug.
author | Paul Eggert <eggert@cs.ucla.edu> |
---|---|
date | Thu, 06 Oct 2005 16:44:39 +0000 |
parents | 88273adcbaf6 |
children | edc0dbc5742f |
files | m4/ChangeLog m4/stdbool.m4 |
diffstat | 2 files changed, 9 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/m4/ChangeLog Thu Oct 06 15:58:26 2005 +0000 +++ b/m4/ChangeLog Thu Oct 06 16:44:39 2005 +0000 @@ -1,3 +1,9 @@ +2005-10-06 Paul Eggert <eggert@cs.ucla.edu> + + * stdbool.m4 (AC_HEADER_STDBOOL): Check that bool + promotes to int, not unsigned int, to catch the AIX 5.3 + compiler bug. + 2005-10-06 Simon Josefsson <jas@extundo.com> * hmac-md5.m4: New file.
--- a/m4/stdbool.m4 Thu Oct 06 15:58:26 2005 +0000 +++ b/m4/stdbool.m4 Thu Oct 06 16:44:39 2005 +0000 @@ -1,6 +1,6 @@ # Check for stdbool.h that conforms to C99. -dnl Copyright (C) 2002-2004 Free Software Foundation, Inc. +dnl Copyright (C) 2002-2005 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. @@ -70,10 +70,11 @@ enum { j = false, k = true, l = false * true, m = true * 256 }; _Bool n[m]; char o[sizeof n == m * sizeof n[0] ? 1 : -1]; + char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1]; ], [ return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !j + !k + !l - + !m + !n + !o); + + !m + !n + !o + !p); ], [ac_cv_header_stdbool_h=yes], [ac_cv_header_stdbool_h=no])])