Article View: comp.lang.c
Article #1295Re: p = {1,0,0}
From: fir
Date: Tue, 03 Nov 2026 14:45
Date: Tue, 03 Nov 2026 14:45
96 lines
4811 bytes
4811 bytes
bartc pisze:
> On 03/11/2026 12:19, fir wrote:
>> bartc pisze:
>
>>>>>>> On 01/11/2026 13:32, fir wrote:
>
>>>>>>>> the fact stat some cannot assign a structure like
>>>>>>>> this
>>>>>>>>
>>>>>>>> s = {x,y};
>>> (It seems to work in my language, provided the expression isn't
>>> 'open'. So 'a := (x, y)' will work, as the LHS helps refine the type,
>>> but not 'print (x, y)' because the types have not been pinned down.)
>>>
>>>
>>
>> [legal note:
>> imo if you take some ideas from me you should credit it (its like "i
>> seen it from the fir "or "as fir said/showed") ..im here speaking
>> generally becouse (i cant find as a copyright police what people took
>> for me and what by the chance no)
>
> You think I stole this 'feature' from your recent post?
>
> In the early 1990s I could write code like this in my scripting language:
>
> p := (100, 200, 300)
> q := (20, 30, 40)
> m := (p + q) / 2
>
wel this is not related..this is not by visual resemblances im talkin
about - but there are some quite deeper observations that i originated
and i know people are generally not honest but for some king of
historical truth this shpould be kept
in this case its somewhat "little" remarks here and its also not about
being stolen coz its free its more like not keeping honesty if things
come form my observations not from other source
what you say here is not related its not a concept of c and what i was
sain about is strictly in c context (and has may qualities of this
context just with some extension)
if you would talk here on tuples in python or c++ is totally different thing
> println m # (60.00, 115.00, 170.00)
>
> It was a 3D graphics application.
>
> In my systems language, it worked like this, and from the 1980s:
>
> record point =
> int x, y
> end
>
> point p = (100, 200) # RHS must be compile-time expr
>
> But general assignments, outside of initialisation and with runtime
> expressions, were not implemented until within the last decade (I can't
> remember exactly as I rarely use the feature, but it was more than two
> days ago). That means being able to do this:
>
> p := (x+1, y)
>
> Such an ability is a natural consequence of the syntax which has always
> been able to express it. It's just a question of (1) whether it has
> useful and desirable semantics; (2) someone has bothered to implement it.
>
> So it has been a thing since the 1980s, and I eventually got around to
> it some decades later.
>
> Notice also that it uses round brackets and not braces.
>
>
>> i know people are not much honest
>> anyway..yet this above is quite not so totally unusual observation
>> (though many undable to dat obeservations) but speaking generally]
>
> Yeah, nobody has thought of having a constructor term like (a, b, c) in
> a PL before you brought it up! Not even in Lisp.
>
> Anyway, DB mentions that C++ has it in the form of {a, b, c}.
>
>> same way {1,2,"assas", 8.9} is value of anonymous structure of type
>> int int char* double (or eventually float)
>
>> no any problem with that imo
>
> How do you access the elements?
>
>
Technical Details
Message-ID:
<11ccs1n$3rd3e$1@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:
<11c7f1j$20b9h$1@dont-email.me> <11c7fj6$20gab$1@dont-email.me> <11cae5m$318tq$1@dont-email.me> <11calrt$34gq3$1@dont-email.me> <11carqs$36m0o$1@dont-email.me> <11cb4hs$3a13l$1@dont-email.me> <11ccjfo$3nvjc$1@dont-email.me> <11ccpr5$3qfhd$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: fir <profesor.fir@gmail.com>
Newsgroups: comp.lang.c
Subject: Re: p = {1,0,0}
Date: Tue, 3 Nov 2026 15:45:10 +0100
Organization: A noiseless patient Spider
Lines: 96
Message-ID: <11ccs1n$3rd3e$1@dont-email.me>
References: <11c7f1j$20b9h$1@dont-email.me> <11c7fj6$20gab$1@dont-email.me>
<11cae5m$318tq$1@dont-email.me> <11calrt$34gq3$1@dont-email.me>
<11carqs$36m0o$1@dont-email.me> <11cb4hs$3a13l$1@dont-email.me>
<11ccjfo$3nvjc$1@dont-email.me> <11ccpr5$3qfhd$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Tue, 03 Nov 2026 14:45:11 +0000 (UTC)
Injection-Info: dont-email.me;
logging-data="4043886"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18xt4C9Z9ZoTC/sorlhsLe43WYMNsJmRiU="; posting-host="74e0b903fc41719bd550775fdb1cba7e"
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:140.0) Gecko/20100101
Firefox/140.0 SeaMonkey/2.53.24
Cancel-Lock: sha1:ghxIO7CGSHXdyJhR9Y8d9KHD9Cs= sha256:wXehVIbvqiIbsyLyhe+F6WPJ1hBL9L2SWx1ia4WFmOA=
sha1:pWdq98xdoNIAw2qzEAp5qxKHN20= sha256:5MG/KePhQH9QZ/lTYu6wJV4X4QALWNuuwHmwI11PX+Y=
In-Reply-To: <11ccpr5$3qfhd$1@dont-email.me>