autoconf
[Top][All Lists]
Advanced

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

Re: AC_HEADER_STDBOOL: checking for _Bool separately for C and C++


From: Paul Eggert
Subject: Re: AC_HEADER_STDBOOL: checking for _Bool separately for C and C++
Date: Tue, 28 Aug 2012 11:34:01 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:14.0) Gecko/20120717 Thunderbird/14.0

On 08/28/2012 10:58 AM, Mojca Miklavec wrote:
> #if HAVE_STDBOOL_H
> # include <stdbool.h>
> #else
> # ifndef __cplusplus
> #  if ! HAVE__BOOL
>     typedef unsigned char _Bool;
> #  endif
> #  define bool _Bool
> #  define false 0
> #  define true 1
> # endif
> // not really needed except to "conform with C99"
> # define __bool_true_false_are_defined 1
> #endif

This doesn't look right, as it means that older
C++ environments won't have _Bool as they should.
I think we need to fix the real problem, somehow,
though I don't use C++ myself and am not the best
person to advise.



reply via email to

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