Deutsch English Français Italiano |
<874j92unoq.fsf@nosuchdomain.example.com> View for Bookmarking (what is this?) Look up another Usenet article |
Path: ...!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Keith Thompson <Keith.S.Thompson+u@gmail.com> Newsgroups: comp.lang.c Subject: Re: technology discussion =?utf-8?Q?=E2=86=92?= does the world need a "new" C ? Date: Sat, 06 Jul 2024 16:04:53 -0700 Organization: None to speak of Lines: 42 Message-ID: <874j92unoq.fsf@nosuchdomain.example.com> References: <v66eci$2qeee$1@dont-email.me> <v67gt1$2vq6a$2@dont-email.me> <v687h2$36i6p$1@dont-email.me> <v68sjv$3a7lb$1@dont-email.me> <v6a76q$3gqkm$6@dont-email.me> <v6b2av$3ofef$1@dont-email.me> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Date: Sun, 07 Jul 2024 01:04:54 +0200 (CEST) Injection-Info: dont-email.me; posting-host="31bef4326a7de5d231f958bc2ab73da5"; logging-data="4185240"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/RzXhjLWEUicfbwXpyvqFS" User-Agent: Gnus/5.13 (Gnus v5.13) Cancel-Lock: sha1:byHpMQ9QLc/m0elrFiLf6GRfnyY= sha1:KjacEt7AsosXB4wn28XAFxA7fJ4= Bytes: 2764 bart <bc@freeuk.com> writes: > On 06/07/2024 02:38, Lawrence D'Oliveiro wrote: >> On Fri, 5 Jul 2024 14:31:44 +0100, bart wrote: >> >>> C also is the only language that is supposed to work on any kind of >>> processor ... >> I don’t think there is anything innate in the design of C to ensure >> that. >> It was simply its popularity that meant it was usually the first language >> implemented on a new processor. >> For example, C assumes byte addressability. > > C didn't define a 'byte' at all. It assumed 'char' addressability, but > allowed that 'char' to be any width at all. I think at some point a > minimum of 8 bits was applied. What??? C defines a "byte" as an "addressable unit of data storage large enough to hold any member of the basic character set of the execution environment". You know that. C references going back to 1974 all talk about bytes (the early ones are specific to the PDP-11). Perhaps you meant that there's no predefined type named "byte", but nobody said there was. The requirement that a byte is at least 8 bits goes back at least to C89. K&R1 (1978) doesn't make this requirement explicit, but shows examples of 8- and 9-bit bytes. [...] > Most of today's hardware evolved from such a model: 32- and 64-bit > words and addresses were an obvious natural progression. C however > still hasn't got the memo. Right, C makes it *so* difficult to support systems with 8-bit bytes and 32- or 64-bit word. -- Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com void Void(void) { Void(); } /* The recursive call of the void */