Path: ...!weretis.net!feeder8.news.weretis.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Keith Thompson Newsgroups: comp.lang.c Subject: Re: how cast works? Date: Thu, 08 Aug 2024 22:55:52 -0700 Organization: None to speak of Lines: 19 Message-ID: <877ccq8ck7.fsf@nosuchdomain.example.com> References: <20240808193203.00006287@yahoo.com> <87frre8v5q.fsf@nosuchdomain.example.com> MIME-Version: 1.0 Content-Type: text/plain Injection-Date: Fri, 09 Aug 2024 07:55:52 +0200 (CEST) Injection-Info: dont-email.me; posting-host="153d1bcdb0929153f62e0b2f2aa4005b"; logging-data="644636"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/nSA2Gg6yBRc37O6L4+daO" User-Agent: Gnus/5.13 (Gnus v5.13) Cancel-Lock: sha1:TC5zNdsmz9zg6QWd1d7AoqsBP+g= sha1:p4mAfQB5Z2ltBOweFxobMxCoPaM= Bytes: 2103 Lawrence D'Oliveiro writes: > On Thu, 08 Aug 2024 16:14:09 -0700, Keith Thompson wrote: >> The value of a _Bool object is always either 0 or 1 *unless* the program >> does something weird. > > If a variable is declared to be of a particular type, does that mean that > any possible value of that variable is, by definition, interpreted as some > instance of that type? Of course, given what "value" means. How could that not be the case? If you mean any possible *representation* (for example, if _Bool is 8 bits there are 256 possible representations), I refer you to my previous discussion of non-value representations (formerly called trap representations) in the text that you snipped. -- Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com void Void(void) { Void(); } /* The recursive call of the void */