Path: ...!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!eternal-september.org!.POSTED!not-for-mail From: Keith Thompson Newsgroups: comp.lang.c Subject: Re: Regarding assignment to struct Date: Wed, 07 May 2025 14:23:57 -0700 Organization: None to speak of Lines: 31 Message-ID: <877c2sf72q.fsf@nosuchdomain.example.com> References: <86plgo7ahu.fsf@linuxsc.com> <87o6w7h2wn.fsf@nosuchdomain.example.com> <868qnb5gg6.fsf@linuxsc.com> <87bjs6hjpo.fsf@nosuchdomain.example.com> <87frhhfq25.fsf@nosuchdomain.example.com> MIME-Version: 1.0 Content-Type: text/plain Injection-Date: Wed, 07 May 2025 23:23:58 +0200 (CEST) Injection-Info: dont-email.me; posting-host="1cb130054d354bd9e3fbb3dd7ef0d101"; logging-data="1313974"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19kB1LcEZ6VfjCR2eeZfNd2" User-Agent: Gnus/5.13 (Gnus v5.13) Cancel-Lock: sha1:h7Qjm5UZBrPaYfzs2VfyOxA7PKA= sha1:wj5+kh/plJ3txE1QZ83+iaq92XE= Bytes: 2670 Nick Bowler writes: > On Tue, 06 May 2025 13:21:38 -0700, Keith Thompson wrote: >> Nick Bowler writes: >>> The rule about conversions from arrays to pointers is different in C99 >>> (n1124 6.3.2.1, third paragraph) compared to C89. In particular, >>> "an lvalue that has type ``array of type'' ..." was changed to >>> "an expression that has type ``array of type'' ...". > [...] >> The change from "lvalue" to "expression" was made in C99. I wonder why >> that was done. > > It's not mentioned in the rationale, so we can only guess. But it is > called out in the list of major changes in the C99 foreword. I've just looked at the foreword of the C99 standard and the n1256 draft, and I couldn't find it. Can you quote the precise wording? >> BTW, you have a copy of ANSI C89? Hard or soft copy? Do you know if >> it's still available in some form? > > Hint: look for FIPS 160 on the NIST website. This is the same standard > as ANSI X3.159-1989 Programming Language - C. includes the 1989 ANSI C standard *and* the ANSI C Rationale. Like many PDFs from that era, it's a scan from printed documents, but it's still possible to copy-and-paste text from the PDF. -- Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com void Void(void) { Void(); } /* The recursive call of the void */