Article View: comp.lang.c
Article #1167Re: .5 against 0.5f
From: Janis Papanagnou
Date: Fri, 30 Oct 2026 13:54
Date: Fri, 30 Oct 2026 13:54
111 lines
6480 bytes
6480 bytes
On 2026-10-30 09:11, David Brown wrote: > On 30/10/2026 04:38, Janis Papanagnou wrote: >> On 2026-10-30 00:56, Keith Thompson wrote: >>> Tim Rentsch <tr.17687@z991.linuxsc.com> writes: >>>> Janis Papanagnou <janis_papanagnou+ng@hotmail.com> writes: >>>>> Note: my argumentation is based on questioning the existence of 'F'. >>>>> So I'd appreciate to hear of any enlightening application cases, ones >>>>> that would be impossible when 'F' in literals wouldn't be present. >>>> >>>> In C the word is constants, not literals. >>> >>> For now. In the latest C2y draft, they're called literals. >>> >>> Proposal: https://www.open-std.org/jtc1/sc22/wg14/www/docs/ >>> n3189.htm >>> Draft standard: https://www.open-std.org/jtc1/sc22/wg14/www/docs/ >>> n3998.pdf >>> >>> (You've said before that you dislike this change.) >>> >>> In any case, the term "literal" is unambiguous, even if it's not >>> currently used by the C standard. >> >> Thanks for answering him. (As I'm yet again ignoring him I wouldn't >> have noticed his statement.) >> >> For other readers I remind that I'm not necessarily using C-standard >> terms if there's terms common in CS existing that either appear more >> appropriately describing things, or if I'm generalizing facts beyond >> "C". > > The preference should be to use the C standard terms in this group - or Like there's no CLC coding style (as recently demanded and rebutted) it's also, IMO, presumptuous to demand posters to use terms defined in the C-standards documents. Moreover, as I recently learned, even the standard-C documents seem to adjust their terminology. As I explained already, I'm using the terms that appear to me to be most appropriate to describe things. In cases where there's multiple options I'm gladly using the terms preferred in the C-standard docs, given that I know them. I certainly consider it presumptuous to demand from posters to read (all or every new version of) the C-standard to talk about "C". > to add brief comments for clarity. (Sometimes it is also worth adding > comments for clarity even when using C standard terms.) The C standard > uses terms like "object" and "byte" in a way that is unusual in the > wider scope of computer science. But sometimes computer science courses > use different terms, as do different programming languages and different > parts of the world, and things change over time - often there is no > single "standard CS" term, and often there is no fixed definition of a > term commonly used in computer science. That's all correct. As I mentioned elsewhere already - I think also in a reply to a post of yours, about the same topic - I'm gladly explaining (if necessary) not only every word in my posts that are unclear to you but also the implied semantics if necessary. (Mind that, as opposed to you and some others, while you may do that, I'm *not* discussing the _C-standard_ here. You should make yourself clear that there's a difference between talking about all aspects of the language or exchange specifically about the formal aspects of "C". What makes perfectly sense for the former group is, to say the least, arguable for the general, non-specialized disputants.) > Many of the terms used in the C > standard have the strong advantage of having specific definitions given > in the standard itself. Fine. > > If in doubt, being a little extra explicit is better than being > misunderstood! No doubt. > > In the particular case of "constant", I think the root issue is that the > word is overused. "integer constant" and "integer constant expression" I think in the post you are referring to I described a different thing; I spoke about a constant literal. And the (IMO unnecessary) dispute had been about "literal" not about "constant". - And we heard that "literal" is even the new term used in the (draft) C-standard! > [snip digressions about "integer constant" and "constant expressions"] > [snip more digressions on early C-"constants"] > [...] C++ has called 123 > an "integer literal" for ages, and it makes sense for C to follow suit. Yes, and I agree with that choice. (I'm using the word "literal" for all programming languages if I want to talk about literals.) > > I doubt if this is the start of a habit or pattern, however. I think it's pointless to make guesses. (I'm certainly continuing to use those terms that I think are best fitting. And if you (or others) have problems understanding them I'm gladly explaining them, as said. Especially since I think the time spent on an explanation of a good term is much better spent than the time wasted for a discussion like the one you restarted here yet another time.) Janis
Technical Details
Message-ID:
<11c27j3$2t866$10@dont-email.me>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mailReferences:
<11bpvs7$1e6kc$2@dont-email.me> <11bqnvh$1np7s$1@dont-email.me> <11br5td$1to7l$1@dont-email.me> <11br792$1u7e5$1@dont-email.me> <11brgqf$21170$2@dont-email.me> <11brir0$1uh9q$4@kst.eternal-september.org> <11bt4ua$139ta$8@dont-email.me> <11btlrl$2ojn1$1@kst.eternal-september.org> <11btv9c$139ta$12@dont-email.me> <86wlr0kzqc.fsf@linuxsc.com> <11c0mfg$3pmvb$4@kst.eternal-september.org> <11c13eq$2t866$6@dont-email.me> <11c1jg6$2kc6$1@dont-email.me>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mail From: Janis Papanagnou <janis_papanagnou+ng@hotmail.com> Newsgroups: comp.lang.c Subject: Re: .5 against 0.5f Date: Fri, 30 Oct 2026 14:54:43 +0100 Organization: A noiseless patient Spider Lines: 111 Message-ID: <11c27j3$2t866$10@dont-email.me> References: <11bpvs7$1e6kc$2@dont-email.me> <11bqnvh$1np7s$1@dont-email.me> <11br5td$1to7l$1@dont-email.me> <11br792$1u7e5$1@dont-email.me> <11brgqf$21170$2@dont-email.me> <11brir0$1uh9q$4@kst.eternal-september.org> <11bt4ua$139ta$8@dont-email.me> <11btlrl$2ojn1$1@kst.eternal-september.org> <11btv9c$139ta$12@dont-email.me> <86wlr0kzqc.fsf@linuxsc.com> <11c0mfg$3pmvb$4@kst.eternal-september.org> <11c13eq$2t866$6@dont-email.me> <11c1jg6$2kc6$1@dont-email.me> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Date: Fri, 30 Oct 2026 13:54:44 +0000 (UTC) Injection-Info: dont-email.me; logging-data="3055814"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+x33m5gyAP6heBMEKDNi1r"; posting-host="0fda1f313dd998dda8e95c4840e29ea0" User-Agent: Mozilla Thunderbird Cancel-Lock: sha1:xTYhU9jq9RIwlA6Y8uLyIkHPXsE= sha256:paGik04bGRgF8VMeoB1kJ03SA9w5lDV93+msPLitfJ0= sha1:PDJIeamVd+cjvlWP0xpWNadPndQ= sha256:VAw9CUUi/ft1LMYcLQoijBUcyXULBrSyCN3q6wHY0wA= In-Reply-To: <11c1jg6$2kc6$1@dont-email.me> Content-Language: en-US