Sujet : Re: Top 10 most common hard skills listed on resumes...
De : ben (at) *nospam* bsb.me.uk (Ben Bacarisse)
Groupes : comp.lang.cDate : 08. Sep 2024, 16:39:02
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <87zfoikve1.fsf@bsb.me.uk>
References : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
User-Agent : Gnus/5.13 (Gnus v5.13)
Bart <
bc@freeuk.com> writes:
In language like C, the LHS of an assignment is one of four categories:
>
A = Y; // name
*X = Y; // pointer
X[i] = Y; // index
X.m = Y; // member select
I can think of three others. There may be more.
A is a simple variable;
C does not define the term "simple variable" so presumably you define it
to be any named object that /can/ appear on the LHS of a simple
assignment -- a sort of "no true Scots-variable".
X represents a term of any complexity, and Y is any
expression.
I can think of at least one expression form for X that contradicts this
claim.
It would be great if C had simple rules, but it doesn't. You could have
started by saying something about the most comment forms of assignment
being those you list, and that X can be almost any term, but the risk of
making absolute claims is that people (like me) will look into them.
(In C, the middle two are really the same thing.)
-- Ben.