Path: ...!news.mixmin.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Bart Newsgroups: comp.lang.c Subject: Re: Top 10 most common hard skills listed on resumes... Date: Wed, 11 Sep 2024 10:52:39 +0100 Organization: A noiseless patient Spider Lines: 39 Message-ID: References: <87o75bwlp8.fsf@bsb.me.uk> <871q27weeh.fsf@bsb.me.uk> <20240829083200.195@kylheku.com> <87v7zjuyd8.fsf@bsb.me.uk> <20240829084851.962@kylheku.com> <87mskvuxe9.fsf@bsb.me.uk> <20240908115827.00007521@yahoo.com> <87zfoikve1.fsf@bsb.me.uk> <87zfofk32t.fsf@bsb.me.uk> <87bk0vjbvz.fsf@bsb.me.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Date: Wed, 11 Sep 2024 11:52:39 +0200 (CEST) Injection-Info: dont-email.me; posting-host="b0e60afe09774e8e7cecec025f09afc9"; logging-data="3697116"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18f/UFgK+FXIxgew0vyyRMr" User-Agent: Mozilla Thunderbird Cancel-Lock: sha1:Au2ollLHM2AY7klG7yjIhz46/aM= In-Reply-To: <87bk0vjbvz.fsf@bsb.me.uk> Content-Language: en-GB Bytes: 3160 On 11/09/2024 01:02, Ben Bacarisse wrote: > Bart writes: >> Sorry, did your remark above suggest I don't know what an lvalue is? > > That seemed like the obvious explanation for the incorrect information > you gave. Did you post it /knowing/ what other kinds of things are > lvalues in C just to confuse people? Which incorrect explanation was that? I merely said that LHSs of assigments fall into these categories: A = Y; // name *X = Y; // pointer X[i] = Y; // index X.m = Y; // member select Clearly I mean VALID LHSs, otherwise they wouldn't be LHSs of assignments! I've since learnt about a couple of other possible categories; one is with compound literals like '(int){42} = 0'. (I don't count (A), ((A)) etc as a separate category; come on!) The other is 'X.m' but when .m is a bitfield; although this has the same same syntax as above, internally it's somewhat different. (My C compiler treats bitfields as ordinary members.) I acknowledge that allowing 'F().m = Y' is wrong; I might get around to fixing it one day. (In my language that would fail when F returns a value struct. It would pass if F returns a pointer to a struct, since I can still use 'F().m := Y', as derefs are automatic. F().m := Y is valid also in my dynamic language, since the returned object can be shared so the effect of the assignment can be observable. But that's really due to underlying pointers too.)