Sujet : Re: question about linker
De : tr.17687 (at) *nospam* z991.linuxsc.com (Tim Rentsch)
Groupes : comp.lang.cDate : 05. Dec 2024, 04:33:53
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <86mshals66.fsf@linuxsc.com>
References : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
User-Agent : Gnus/5.11 (Gnus v5.11) Emacs/22.4 (gnu/linux)
Michael S <
already5chosen@yahoo.com> writes:
On Fri, 29 Nov 2024 13:33:30 +0000
Bart <bc@freeuk.com> wrote:
>
[C syntax] allows a list of variable names in the same declaration
to each have their own modifiers, so each can be a totally
different type
>
Not in every context. It is not allowed in function prototypes.
Even when it is allowed, it's never necessary and avoided by
majority of experienced programmers.
I'd guess, TimR will disagree with the last part.
I might say I mostly agree. Most of the declarations I write
have only one declarator. I don't have an absolute rule against
declaring multiple names in a single declaration; depending on
what is being declared and on other circumstances it might look
reasonable. Generally I find rules that admit no exceptions
under any circumstances to be unnecessarily rigid. These days
it's the fashion to treat programmers like they're dumb and
incapable of exercising good independent judgment. I have a
different view.