Path: csiph.com!news.swapon.de!eternal-september.org!feeder.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Keith Thompson Newsgroups: comp.lang.c Subject: Re: Why _Bool was not defined as enum in C99? Date: Tue, 13 Sep 2016 18:17:59 -0700 Organization: None to speak of Lines: 30 Message-ID: References: <6b5aa241-0498-4e41-993b-a1ed445effb0@googlegroups.com> <871t0osuq6.fsf@bsb.me.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: mx02.eternal-september.org; posting-host="945944de09706c9b4e29b53c9d2efdc2"; logging-data="8525"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/xHMmFVbdVIMCgqeNSRZYs" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) Cancel-Lock: sha1:+F0NT5p6QkoEjkaI+iV0p1QGnqg= sha1:VJwWTCBZEIgBLKIvJCm7Ms0KFEw= Xref: csiph.com comp.lang.c:93453 Tim Rentsch writes: > Ben Bacarisse writes: > >> thiago.adams@gmail.com writes: >> >>> Does anyone knows if an enumeration was considered to implement _Bool? >> >> I image a strong reason it would not have got through is the desire to >> be compatible with the semantics of C++'s bool which does not behave >> like an enumerated type. [...] > > I believe bool in C++ and _Bool in C were developed more or less > contemporaneously. (C++ added 'bool' in C++98.) That doesn't > contradict your statement, but it suggests the relationship > may have been one more of synergy than causality. (Let me > emphasize that I have no facts beyond when 'bool' was added > to C++. I don't know anything, I'm just speculating.) Hmm. C++98 was the first C++ standard. Did pre-standard C++ not have bool before that? (I have books that would answer that, but they're not handy.) (The C99 Rationale doesn't provide any useful information on the history of _Bool.) -- Keith Thompson (The_Other_Keith) kst-u@mib.org Working, but not speaking, for JetHead Development, Inc. "We must do something. This is something. Therefore, we must do this." -- Antony Jay and Jonathan Lynn, "Yes Minister"