Groups | Search | Server Info | Keyboard shortcuts | Login | Register
Groups > comp.lang.c > #392396
| From | Tim Rentsch <tr.17687@z991.linuxsc.com> |
|---|---|
| Newsgroups | comp.lang.c |
| Subject | Re: "A diagram of C23 basic types" |
| Date | 2025-04-11 09:48 -0700 |
| Organization | A noiseless patient Spider |
| Message-ID | <8634eebq5w.fsf@linuxsc.com> (permalink) |
| References | <87y0wjaysg.fsf@gmail.com> |
Alexis <flexibeast@gmail.com> writes: > Thought people here might be interested in this image on Jens Gustedt's > blog, which translates section 6.2.5, "Types", of the C23 standard > into a graph of inclusions: > > https://gustedt.wordpress.com/2025/03/29/a-diagram-of-c23-basic-types/ By the way, regarding the question of why types like size_t are not in the diagram, there is a simple explanation. All the types shown in the diagram are guaranteed to be distinct.[*] Types like size_t, ptrdiff_t, and so forth, are not new types, but simply different names for a type already represented in the diagram. [*] This statement assumes that a bit-precise type whose width matches one of the standard integer types is still a distinct type. I don't know if C23 actually follows that rule. Editorial comment: my understanding is that there is an asymmetry regarding the bit-precise types, in that there is an unsigned bit-precise type of width 1, but not a signed bit-precise type of width 1. Assuming that is so, IMO it is a galactically stupid omission: a signed bit-precise integer of width 1 would very naturally hold the two values 0 and -1, which is a useful type to have in some circumstances, and symmetry would be preserved. Someone didn't have their Wheaties that morning when that decision was made.
Back to comp.lang.c | Previous | Next — Next in thread | Find similar
Re: "A diagram of C23 basic types" Tim Rentsch <tr.17687@z991.linuxsc.com> - 2025-04-11 09:48 -0700 Re: "A diagram of C23 basic types" Keith Thompson <Keith.S.Thompson+u@gmail.com> - 2025-04-11 13:51 -0700
csiph-web