Thread View: comp.lang.c
103 messages
103 total messages
Page 2 of 3
Started by fir
Fri, 23 Oct 2026 05:44
Page 2 of 3 • 103 total messages
Re: variadic min and max, (any some and none, cat and more)
Author: fir
Date: Mon, 26 Oct 2026 11:30
Date: Mon, 26 Oct 2026 11:30
179 lines
8105 bytes
8105 bytes
fir pisze:
> Chris M. Thomasson pisze:
>> On 10/25/2026 5:32 PM, fir wrote:
>>> Chris M. Thomasson pisze:
>>>> On 10/25/2026 11:04 AM, fir wrote:
>>>>> fir pisze:
>>>>>> bartc pisze:
>>>>>>> On 25/10/2026 11:01, fir wrote:
>>>>>>>> ichard Harnden pisze:> On 23/10/2026 06:44, fir wrote:
>>>>>>>> >> when thinkong on variadic functions not much come to mind but
>>>>>>>> >> only recently i noticed min or max would be good for variadic
>>>>>>>> >>
>>>>>>>> >> the ai wrote me such variadic min
>>>>>>>> >
>>>>>>>> > I don't think that I'd bother with stdarg at all.
>>>>>>>> >
>>>>>>>> > Just use a string of ints ...
>>>>>>>> >
>>>>>>>> > int min(const int *n)
>>>>>>>> > {
>>>>>>>> > int m = INT_MAX;
>>>>>>>> >
>>>>>>>> > while ( *n )
>>>>>>>> > {
>>>>>>>> > if ( *n < m ) m = *n;
>>>>>>>> >
>>>>>>>> > n++;
>>>>>>>> > }
>>>>>>>> >
>>>>>>>> > return m;
>>>>>>>> > }
>>>>>>>> >
>>>>>>>> >> int a=Min(4,10,3,7,-2); // -2
>>>>>>>> >
>>>>>>>> > int a = min((int[]){10,3,7,-2}));
>>>>>>>> >
>>>>>>>> >
>>>>>>>> >
>>>>>>>> such thig should be builtin nd automatic there are hovever some
>>>>>>>> decisions toconclude for example
>>>>>>>>
>>>>>>>> foo(float3 x);
>>>>>>>> goo(float3* x);
>>>>>>>>
>>>>>>>> foo({1,2,4.});
>>>>>>>>
>>>>>>>> goo({2,3,4}) or goo(&{2,3,4})
>>>>>>>>
>>>>>>>> or maybe allowing to drop {} at all
>>>>>>>> foo(1,2,4.);
>>>>>>>
>>>>>>> So:
>>>>>>>
>>>>>>> foo(float3 x, float3 y, int n);
>>>>>>>
>>>>>>> can be called as:
>>>>>>>
>>>>>>> foo(1, 2, 3, 4, 5, 6, 7);
>>>>>>>
>>>>>>
>>>>>> well its a question what to put as a mandatory.. i dont know yet,
>>>>>> but for sure thise automatic 'fitting' would be somewhat good
>>>>>>
>>>>>> some can write
>>>>>>
>>>>>> foo({1, 2, 3}, {4, 5, 6}, 7);
>>>>>>
>>>>>> and you again present anti-c philosophy
>>>>>>
>>>>>> c allows you write programs ale obfuscated c contests..in your
>>>>>> philosofy
>>>>>> you would forbide it all? forcing codes not have syttaktic shortcuts?
>>>>>>
>>>>>> i totally not agree to such philosophy
>>>>>>
>>>>>> (though its not always clear whay s good shortcut/hack c way and
>>>>>> what is not)
>>>>>>
>>>>>>
>>>>>>
>>>>>>> It's so easy to see where one argument ends and another begins!
>>>>>>> And this is the simplest possible set of arguments.
>>>>>>>
>>>>>>> Still, C has prior art here:
>>>>>>>
>>>>>>> typedef struct {float x,y,z;} float3;
>>>>>>> typedef struct {float3 a, b; int c;} T;
>>>>>>>
>>>>>>> T x = {1, 2, 3, 4, 5, 6, 7};
>>>>>>>
>>>>>>> So that would fit right in!
>>>>>>>
>>>>>>>
>>>>>>
>>>>> recent state of my rasterizer toying btw
>>>>>
>>>>> https://www.youtube.com/watch?v=xERLKVTV9s8
>>>>>
>>>>> those pices of geometry was generated by ai ...sadly when adding
>>>>> more geometry the rasterizer get slowing down ofs..and i have no
>>>>> best cpu
>>>>
>>>> Too bad you need an AI to make it for you.
>>>>
>>>
>>>
>>> you talk like medevial peasnt such your remarks here
>>>
>>> you know for some people accustomed to higher social standards you
>>> may be perceive you as a bit of a country bumpkin (sorry i dont
>>> understand this phrase its form translation, i m not quite sure what
>>> bumpkin is - i meant more like peasent, medevial villager)
>>>
>>> its not quite good to enforce you peasnty belifs on
>>> people...especially as it seems you totally dont know what youre
>>> talkin about
>>>
>>> i already told you so but it seems youre like dont get it
>>>
>>>
>>> as to rasterizer its nice to shape the pixell matter..though i need much
>>> stronger cpu, i need like 100x stronger..and it doesnt seem i would
>>> get it..though GPU in fact maybe might be so
>>>
>>> or meybe i should learn more multithreading and put it on 8 10 or 12
>>> cores... im not sure but not being experienced in this it seems that
>>> rasterisation should be quite good for multithreading - simply run 1/10
>>> of objects in the scene on 10 cores into 10 output buffers..then "add"
>>> the buffers... this depth buffers seem ideal for adding
>>>
>>> im not yet sure if it really works that way - but if it does its
>>> finally a reason to buy a desktop pc iwth many cores
>>>
>>>
>>>
>>>>>
>>>>> though modern are maybe 2-3 times faster at most i guess
>>>>
>>>
>>
>> Not really, just buy something with a half way decent GPU, or even a
>> crappy one. NVIDIA has some cheap ones. The learn how to code for it.
>
> there is no chea nvidia GPU at stores right now.. i maybe should stil
> wait if they get nootably cheaper and buy some
>
> more important gpu koding is different kind of coding... this rasterizer
> btw i coded in formal C now (as ported from old version c via c++)
> though those linker errors when i
> i call i function name which i it cant find annoys me i could say
> (in c via c++ thre eas no such thing as i remember)
>
>
> as to AI it so much grat i could probably name a list of 100
> (or at least 30) big advantages of it where 2-3 could be suffice to use it
>
> you noticed i criticize your 'peasenty' attitude but really learn what
> you talkin about becouse stating things when you got no idea what youre
> talkin about is absolutely not usenet is for
>
> usenet was always good people here focus on validating opinions and
> what you say like that: i have no idea what im talking about yet i
> will say opposite to truth is not standable here
>
> take given point you learned if something is wrong in that point
> criticize it in valid ay if you must ... or praise it if its good
> becouse this seconnd attempt is arso quite valueable i such new topic
> when people need to learn that
>
dont know how to do it - download chatgpt from windows store or
(slightly worse imo) open t in web and ask the programming speific
questions you will be impressed 0 instead of talkin bulshit on
the net as many do
(ofc paying questions may be a problem but now yhe free versions go on
quite well - and i hope it will stay this way becouse if those firms use
so much public material made by anybody they should be obliged to return
part of it as free decend versions im (it should be even regulated by
law maybe as some kind of payback to society... but for now its ok)
Re: variadic min and max, (any some and none, cat and more)
Author: bartc
Date: Mon, 26 Oct 2026 12:07
Date: Mon, 26 Oct 2026 12:07
50 lines
3702 bytes
3702 bytes
On 26/10/2026 11:30, fir wrote: >> >> take given point you learned if something is wrong in that point >> criticize it in valid ay if you must ... or praise it if its good >> becouse this seconnd attempt is arso quite valueable i such new topic >> when people need to learn that >> > dont know how to do it - download chatgpt from windows store or > (slightly worse imo) open t in web and ask the programming speific > questions you will be impressed 0 instead of talkin bulshit on > the net as many do > > (ofc paying questions may be a problem but now yhe free versions go on > quite well - and i hope it will stay this way It won't. Get everyone hooked first then start charging. becouse if those firms use > so much public material made by anybody they should be obliged to return > part of it as free decend versions im (it should be even regulated by > law maybe as some kind of payback to society... but for now its ok) Take whatever application it is that AI is helping you create. Suppose you found that somebody had already created a working application that worked exactly as you wanted (maybe using AI more effectively!), and it was a free download. What you stop your development and just use that product? Or is development the interesting bit? Take all these ideas about new language features that you have posted about extensively. Did you know that AI can be used to help devise new languages and even implement them for you? Would you do that too? (Since nobody here is going to develop your dream language for you. I've already done mine.) But then, if AI is going to be writing the code anyway, what difference does it make what language it generates? It might as well generate machine code directly. Also, is your product a game that you have to try and win? Would you tell AI to play the game to win it for you? If not, why not? Can you not see that taking AI's capabilities to the extremes makes it all pointless? At least, for recreational purposes. Its other main purpose seems to be taking over as many people's jobs as possible.
Re: variadic min and max, (any some and none, cat and more)
Author: fir
Date: Mon, 26 Oct 2026 12:51
Date: Mon, 26 Oct 2026 12:51
87 lines
5303 bytes
5303 bytes
bartc pisze: > On 26/10/2026 11:30, fir wrote: > >>> >>> take given point you learned if something is wrong in that point >>> criticize it in valid ay if you must ... or praise it if its good >>> becouse this seconnd attempt is arso quite valueable i such new topic >>> when people need to learn that >>> >> dont know how to do it - download chatgpt from windows store or >> (slightly worse imo) open t in web and ask the programming speific >> questions you will be impressed 0 instead of talkin bulshit on >> the net as many do >> >> (ofc paying questions may be a problem but now yhe free versions go on >> quite well - and i hope it will stay this way > > It won't. Get everyone hooked first then start charging. > > becouse if those firms use >> so much public material made by anybody they should be obliged to >> return part of it as free decend versions im (it should be even >> regulated by law maybe as some kind of payback to society... but for >> now its ok) > > Take whatever application it is that AI is helping you create. Suppose > you found that somebody had already created a working application that > worked exactly as you wanted (maybe using AI more effectively!), and it > was a free download. > > What you stop your development and just use that product? Or is > development the interesting bit? > > Take all these ideas about new language features that you have posted > about extensively. Did you know that AI can be used to help devise new > languages and even implement them for you? > > Would you do that too? (Since nobody here is going to develop your dream > language for you. I've already done mine.) > > But then, if AI is going to be writing the code anyway, what difference > does it make what language it generates? It might as well generate > machine code directly. > > Also, is your product a game that you have to try and win? Would you > tell AI to play the game to win it for you? If not, why not? > > Can you not see that taking AI's capabilities to the extremes makes it > all pointless? At least, for recreational purposes. > > Its other main purpose seems to be taking over as many people's jobs as > possible. world needs to work to be done not to work to be done + eople suffer sittin doin it too much ;c ai just helps work be done so what is the problem here? i generally dont see any problem alos you you think i ame doing something and someone ele was doin it aith ai... overally if you do things it is so called combinatoric explosion or maybe more combinatoric hyperexplosion even ai cant fit in exact the same what someone could be doing imo as if you only need to take 100 binary decisions then te chance is 1/2^100 and someone takes even more decisions and they are non binary ofsc ai eventaully could take some other better than yours but if so it just sis other thing overally people have absolutely crazy opinions here..its liek someone gave you milion dollars and you will be screaming "its bad" its takin my job (or other weird things)..it takes jobs ofc but as the job will be done what is the problem - if someone really loves such kind of jibs they may do it eventually for no money just as a kind of Historical reenactors group i may understood its pitty no people ride in a horse-drawn carriage but if someone get back to it i guess it would show its not so much good besides ai is an option liek many things in life, i just love my chat gpt app really you should try if you not used it its tptally amazing wspecially in coding
Re: variadic min and max, (any some and none, cat and more)
Author: fir
Date: Mon, 26 Oct 2026 13:00
Date: Mon, 26 Oct 2026 13:00
103 lines
6233 bytes
6233 bytes
fir pisze: > bartc pisze: >> On 26/10/2026 11:30, fir wrote: >> >>>> >>>> take given point you learned if something is wrong in that point >>>> criticize it in valid ay if you must ... or praise it if its good >>>> becouse this seconnd attempt is arso quite valueable i such new >>>> topic when people need to learn that >>>> >>> dont know how to do it - download chatgpt from windows store or >>> (slightly worse imo) open t in web and ask the programming speific >>> questions you will be impressed 0 instead of talkin bulshit on >>> the net as many do >>> >>> (ofc paying questions may be a problem but now yhe free versions go >>> on quite well - and i hope it will stay this way >> >> It won't. Get everyone hooked first then start charging. >> >> becouse if those firms use >>> so much public material made by anybody they should be obliged to >>> return part of it as free decend versions im (it should be even >>> regulated by law maybe as some kind of payback to society... but for >>> now its ok) >> >> Take whatever application it is that AI is helping you create. Suppose >> you found that somebody had already created a working application that >> worked exactly as you wanted (maybe using AI more effectively!), and >> it was a free download. >> >> What you stop your development and just use that product? Or is >> development the interesting bit? >> >> Take all these ideas about new language features that you have posted >> about extensively. Did you know that AI can be used to help devise new >> languages and even implement them for you? >> >> Would you do that too? (Since nobody here is going to develop your >> dream language for you. I've already done mine.) >> >> But then, if AI is going to be writing the code anyway, what >> difference does it make what language it generates? It might as well >> generate machine code directly. >> >> Also, is your product a game that you have to try and win? Would you >> tell AI to play the game to win it for you? If not, why not? >> >> Can you not see that taking AI's capabilities to the extremes makes it >> all pointless? At least, for recreational purposes. >> >> Its other main purpose seems to be taking over as many people's jobs >> as possible. > > world needs to work to be done not to work to be done + eople suffer > sittin doin it too much ;c > > ai just helps work be done so what is the problem here? > i generally dont see any problem > > > alos you you think i ame doing something and someone ele was doin it > aith ai... overally if you do things it is so called combinatoric > explosion or maybe more combinatoric hyperexplosion even ai cant fit > in exact the same what someone could be doing imo as if you only need to > take 100 binary decisions then te chance is 1/2^100 and someone takes > even more decisions and they are non binary > > > ofsc ai eventaully could take some other better than yours but if so > it just sis other thing > > overally people have absolutely crazy opinions here..its liek someone > gave you milion dollars and you will be screaming "its bad" its takin my > job (or other weird things)..it takes jobs ofc but as the job will be > done what is the problem - if someone really loves such kind of jibs > they may do it eventually for no money just as a kind of Historical > reenactors group > > i may understood its pitty no people ride in a horse-drawn carriage > but if someone get back to it i guess it would show its not so much > good > > besides ai is an option liek many things in life, i just love my chat > gpt app > > really you should try if you not used it its tptally amazing wspecially > in coding nota also AI is not good in ALL things..i for example observed its good when there is soeta wll defined problem but if you tell it to design solution for a bit vague problem its not necessary you get answer better than you would design it like say design good "something" (i dont know d game/ or routine for npc behaviour..etc..such kinda not quite defined things)..those design it takes are not necessary the best..whough thay may be good as start its quite fresh thing this ai so im not sure if its weakneses and strong sides are alteady reckognized (also for example by me)..so mabe things will show.. but as what i noticed its not like it gaves you best solution for anything but what it gave in various topics is amazing/ amazingly helpfull
Re: variadic min and max, (any some and none, cat and more)
Author: fir
Date: Mon, 26 Oct 2026 13:06
Date: Mon, 26 Oct 2026 13:06
116 lines
6913 bytes
6913 bytes
fir pisze: > fir pisze: >> bartc pisze: >>> On 26/10/2026 11:30, fir wrote: >>> >>>>> >>>>> take given point you learned if something is wrong in that point >>>>> criticize it in valid ay if you must ... or praise it if its good >>>>> becouse this seconnd attempt is arso quite valueable i such new >>>>> topic when people need to learn that >>>>> >>>> dont know how to do it - download chatgpt from windows store or >>>> (slightly worse imo) open t in web and ask the programming speific >>>> questions you will be impressed 0 instead of talkin bulshit on >>>> the net as many do >>>> >>>> (ofc paying questions may be a problem but now yhe free versions go >>>> on quite well - and i hope it will stay this way >>> >>> It won't. Get everyone hooked first then start charging. >>> >>> becouse if those firms use >>>> so much public material made by anybody they should be obliged to >>>> return part of it as free decend versions im (it should be even >>>> regulated by law maybe as some kind of payback to society... but for >>>> now its ok) >>> >>> Take whatever application it is that AI is helping you create. >>> Suppose you found that somebody had already created a working >>> application that worked exactly as you wanted (maybe using AI more >>> effectively!), and it was a free download. >>> >>> What you stop your development and just use that product? Or is >>> development the interesting bit? >>> >>> Take all these ideas about new language features that you have posted >>> about extensively. Did you know that AI can be used to help devise >>> new languages and even implement them for you? >>> >>> Would you do that too? (Since nobody here is going to develop your >>> dream language for you. I've already done mine.) >>> >>> But then, if AI is going to be writing the code anyway, what >>> difference does it make what language it generates? It might as well >>> generate machine code directly. >>> >>> Also, is your product a game that you have to try and win? Would you >>> tell AI to play the game to win it for you? If not, why not? >>> >>> Can you not see that taking AI's capabilities to the extremes makes >>> it all pointless? At least, for recreational purposes. >>> >>> Its other main purpose seems to be taking over as many people's jobs >>> as possible. >> >> world needs to work to be done not to work to be done + eople suffer >> sittin doin it too much ;c >> >> ai just helps work be done so what is the problem here? >> i generally dont see any problem >> >> >> alos you you think i ame doing something and someone ele was doin it >> aith ai... overally if you do things it is so called combinatoric >> explosion or maybe more combinatoric hyperexplosion even ai cant fit >> in exact the same what someone could be doing imo as if you only need >> to take 100 binary decisions then te chance is 1/2^100 and someone takes >> even more decisions and they are non binary >> >> >> ofsc ai eventaully could take some other better than yours but if so >> it just sis other thing >> >> overally people have absolutely crazy opinions here..its liek someone >> gave you milion dollars and you will be screaming "its bad" its takin >> my job (or other weird things)..it takes jobs ofc but as the job will >> be done what is the problem - if someone really loves such kind of >> jibs they may do it eventually for no money just as a kind of >> Historical reenactors group >> >> i may understood its pitty no people ride in a horse-drawn carriage >> but if someone get back to it i guess it would show its not so much >> good >> >> besides ai is an option liek many things in life, i just love my chat >> gpt app >> >> really you should try if you not used it its tptally amazing >> wspecially in coding > > nota also AI is not good in ALL things..i for example observed its good > when there is soeta wll defined problem but if you tell it to design > solution for a bit vague problem its not necessary you get answer better > than you would design it > > like say design good "something" (i dont know d game/ or routine for npc > behaviour..etc..such kinda not quite defined things)..those design it > takes are not necessary the best..whough thay may be good as start > > its quite fresh thing this ai so im not sure if its weakneses and strong > sides are alteady reckognized (also for example by me)..so mabe things > will show.. but as what i noticed its not like it gaves you best > solution for anything but what it gave in various topics is amazing/ > amazingly helpfull imo some people should accept that (like here on this group, its my good advice) AND just go into details inside it as its very good think worth discussing and studying if soem like coding in c or likes c topic as language imo it should also like learning talking with ai and what he can get with that (id someone is to pold or something that nothing is interesting to him i can do nothing, though fortunallelly it shows i not yet obtained that point fortunatelly - and i find such tjings quite interesting)
Re: variadic min and max, (any some and none, cat and more)
Author: bartc
Date: Mon, 26 Oct 2026 14:09
Date: Mon, 26 Oct 2026 14:09
16 lines
2144 bytes
2144 bytes
On 26/10/2026 12:51, fir wrote: > bartc pisze: >> Can you not see that taking AI's capabilities to the extremes makes it >> all pointless? At least, for recreational purposes. >> >> Its other main purpose seems to be taking over as many people's jobs >> as possible. > overally people have absolutely crazy opinions here..its liek someone > gave you milion dollars and you will be screaming "its bad" Actually yes. What would happen if /everybody/ was given a million dollars? Think about it.
Re: variadic min and max, (any some and none, cat and more)
Author: fir
Date: Mon, 26 Oct 2026 14:15
Date: Mon, 26 Oct 2026 14:15
20 lines
2419 bytes
2419 bytes
bartc pisze: > On 26/10/2026 12:51, fir wrote: >> bartc pisze: > >>> Can you not see that taking AI's capabilities to the extremes makes >>> it all pointless? At least, for recreational purposes. >>> >>> Its other main purpose seems to be taking over as many people's jobs >>> as possible. > >> overally people have absolutely crazy opinions here..its liek someone >> gave you milion dollars and you will be screaming "its bad" > > Actually yes. What would happen if /everybody/ was given a million > dollars? Think about it. > > this is a million dolars ov value not empty paper money, ai gives such value that 1 milion per capita is imo quite comparable
Re: variadic min and max, (any some and none, cat and more)
Author: bartc
Date: Mon, 26 Oct 2026 14:28
Date: Mon, 26 Oct 2026 14:28
44 lines
3150 bytes
3150 bytes
On 26/10/2026 14:15, fir wrote: > bartc pisze: >> On 26/10/2026 12:51, fir wrote: >>> bartc pisze: >> >>>> Can you not see that taking AI's capabilities to the extremes makes >>>> it all pointless? At least, for recreational purposes. >>>> >>>> Its other main purpose seems to be taking over as many people's jobs >>>> as possible. >> >>> overally people have absolutely crazy opinions here..its liek someone >>> gave you milion dollars and you will be screaming "its bad" >> >> Actually yes. What would happen if /everybody/ was given a million >> dollars? Think about it. >> >> > this is a million dolars ov value not empty paper money, ai gives such > value that 1 milion per capita is imo quite comparable > Well, $1m wouldn't have quite as much value if every individual on earth was a millionaire. But the first thing that would happen is that most people would not bother going to work (because they're now rich!) and everything would stop working. Likely followed by hyperinflation. Actually, if you type in: "suppose everybody everybody was given $1000000" into google, your beloved AI gives the same sort of picture. Namely (it goes into a lot more detail): Instant Hyperinflation Supply Chain and Labour Collapse Destruction of Savings and Debt Of course, if it was just me, I'd take it! And if I was the only person on earth with access to AI, that would also be invaluable.
Re: variadic min and max, (any some and none, cat and more)
Author: fir
Date: Mon, 26 Oct 2026 15:48
Date: Mon, 26 Oct 2026 15:48
53 lines
3687 bytes
3687 bytes
bartc pisze: > On 26/10/2026 14:15, fir wrote: >> bartc pisze: >>> On 26/10/2026 12:51, fir wrote: >>>> bartc pisze: >>> >>>>> Can you not see that taking AI's capabilities to the extremes makes >>>>> it all pointless? At least, for recreational purposes. >>>>> >>>>> Its other main purpose seems to be taking over as many people's >>>>> jobs as possible. >>> >>>> overally people have absolutely crazy opinions here..its liek >>>> someone gave you milion dollars and you will be screaming "its bad" >>> >>> Actually yes. What would happen if /everybody/ was given a million >>> dollars? Think about it. >>> >>> >> this is a million dolars ov value not empty paper money, ai gives such >> value that 1 milion per capita is imo quite comparable >> > > Well, $1m wouldn't have quite as much value if every individual on earth > was a millionaire. > > But the first thing that would happen is that most people would not > bother going to work (because they're now rich!) and everything would > stop working. > > Likely followed by hyperinflation. > > Actually, if you type in: "suppose everybody everybody was given > $1000000" into google, your beloved AI gives the same sort of picture. > > Namely (it goes into a lot more detail): > > Instant Hyperinflation > Supply Chain and Labour Collapse > Destruction of Savings and Debt > > Of course, if it was just me, I'd take it! And if I was the only person > on earth with access to AI, that would also be invaluable. > > sadly you say nonsense here ...first some complain of losing jobs then switchung to state where there are jobs and people not take it.. also this is no case of hiperinflation is more liek oposite when work is much cheeper things go cheaper so many people dont get basics and talk crazy things - i dont want toparticipate in crazy talk
Re: variadic min and max, (any some and none, cat and more)
Author: fir
Date: Mon, 26 Oct 2026 16:33
Date: Mon, 26 Oct 2026 16:33
37 lines
2859 bytes
2859 bytes
Lawrence D’Oliveiro pisze: > On Sun, 25 Oct 2026 15:58:58 -0700, Chris M. Thomasson wrote: > >> On 10/25/2026 2:56 PM, Lawrence D’Oliveiro wrote: >>> >>> On Sun, 25 Oct 2026 14:44:15 -0700, Chris M. Thomasson wrote: >>> >>>> If you want some free models to work with. check out SketchFab. >>> >>> Aren’t they more oriented towards 3D printing? >> >> Well, fir should know how to load a 3d model and light it. > > There are better sources of models for on-screen work. > > Sci-fi fan? How about this <https://trekmeshes.eu/>. > those are prioprietary more or less ai generates quite nice models imo https://www.youtube.com/watch?v=PeTMNf4Z8q4 and whats great there are like i get the legal rights to them at least in such extnt i can uise them - which is great becouse even if tehre are free models in the net i dont like the dependencies of such type and here is liek i get rights to this stations and ships possibly not agressive that someone can generate the same or close and he has also rights to thuis and its also very good as i dont like agresive copyrights but startrek is ok and i could eventually even download and load thse models just tos see how it look
Re: variadic min and max, (any some and none, cat and more)
Author: bartc
Date: Mon, 26 Oct 2026 16:36
Date: Mon, 26 Oct 2026 16:36
64 lines
3888 bytes
3888 bytes
On 26/10/2026 15:48, fir wrote: > bartc pisze: >> On 26/10/2026 14:15, fir wrote: >>> bartc pisze: >>>> On 26/10/2026 12:51, fir wrote: >>>>> bartc pisze: >>>> >>>>>> Can you not see that taking AI's capabilities to the extremes >>>>>> makes it all pointless? At least, for recreational purposes. >>>>>> >>>>>> Its other main purpose seems to be taking over as many people's >>>>>> jobs as possible. >>>> >>>>> overally people have absolutely crazy opinions here..its liek >>>>> someone gave you milion dollars and you will be screaming "its bad" >>>> >>>> Actually yes. What would happen if /everybody/ was given a million >>>> dollars? Think about it. >>>> >>>> >>> this is a million dolars ov value not empty paper money, ai gives >>> such value that 1 milion per capita is imo quite comparable >>> >> >> Well, $1m wouldn't have quite as much value if every individual on >> earth was a millionaire. >> >> But the first thing that would happen is that most people would not >> bother going to work (because they're now rich!) and everything would >> stop working. >> >> Likely followed by hyperinflation. >> >> Actually, if you type in: "suppose everybody everybody was given >> $1000000" into google, your beloved AI gives the same sort of picture. >> >> Namely (it goes into a lot more detail): >> >> Instant Hyperinflation >> Supply Chain and Labour Collapse >> Destruction of Savings and Debt >> >> Of course, if it was just me, I'd take it! And if I was the only >> person on earth with access to AI, that would also be invaluable. >> >> > sadly you say nonsense here ...first some complain of losing jobs then > switchung to state where there are jobs and people not take it.. > > also this is no case of hiperinflation That is literally what Google's AI reported. is more liek oposite when work is > much cheeper things go cheaper If AI is available to everybody, and it can do anything, then why would they need you, or your product? Unless your product is AI. > so many people dont get basics and talk crazy things Yeah...
This is rich... (Was: variadic min and max, (any some and none, cat and more))
Author: Kenny McCormack
Date: Mon, 26 Oct 2026 17:47
Date: Mon, 26 Oct 2026 17:47
11 lines
1492 bytes
1492 bytes
In article <11bnvi2$oo6k$1@dont-email.me>, "fir" wrote: ... >> so many people dont get basics and talk crazy things This is rich, coming from "fir"... -- The randomly chosen signature file that would have appeared here is more than 4-ish lines long. As such, it violates one or more Usenet RFCs. In order to remain in compliance with said RFCs, the actual sig can be found at the following URL: http://user.xmission.com/~gazelle/Sigs/RepInsults
Re: variadic min and max, (any some and none, cat and more)
Author: Chris M. Thomasson
Date: Mon, 26 Oct 2026 19:38
Date: Mon, 26 Oct 2026 19:38
183 lines
8075 bytes
8075 bytes
On 10/26/2026 4:27 AM, fir wrote:
> Chris M. Thomasson pisze:
>> On 10/25/2026 5:32 PM, fir wrote:
>>> Chris M. Thomasson pisze:
>>>> On 10/25/2026 11:04 AM, fir wrote:
>>>>> fir pisze:
>>>>>> bartc pisze:
>>>>>>> On 25/10/2026 11:01, fir wrote:
>>>>>>>> ichard Harnden pisze:> On 23/10/2026 06:44, fir wrote:
>>>>>>>> >> when thinkong on variadic functions not much come to mind but
>>>>>>>> >> only recently i noticed min or max would be good for variadic
>>>>>>>> >>
>>>>>>>> >> the ai wrote me such variadic min
>>>>>>>> >
>>>>>>>> > I don't think that I'd bother with stdarg at all.
>>>>>>>> >
>>>>>>>> > Just use a string of ints ...
>>>>>>>> >
>>>>>>>> > int min(const int *n)
>>>>>>>> > {
>>>>>>>> > int m = INT_MAX;
>>>>>>>> >
>>>>>>>> > while ( *n )
>>>>>>>> > {
>>>>>>>> > if ( *n < m ) m = *n;
>>>>>>>> >
>>>>>>>> > n++;
>>>>>>>> > }
>>>>>>>> >
>>>>>>>> > return m;
>>>>>>>> > }
>>>>>>>> >
>>>>>>>> >> int a=Min(4,10,3,7,-2); // -2
>>>>>>>> >
>>>>>>>> > int a = min((int[]){10,3,7,-2}));
>>>>>>>> >
>>>>>>>> >
>>>>>>>> >
>>>>>>>> such thig should be builtin nd automatic there are hovever some
>>>>>>>> decisions toconclude for example
>>>>>>>>
>>>>>>>> foo(float3 x);
>>>>>>>> goo(float3* x);
>>>>>>>>
>>>>>>>> foo({1,2,4.});
>>>>>>>>
>>>>>>>> goo({2,3,4}) or goo(&{2,3,4})
>>>>>>>>
>>>>>>>> or maybe allowing to drop {} at all
>>>>>>>> foo(1,2,4.);
>>>>>>>
>>>>>>> So:
>>>>>>>
>>>>>>> foo(float3 x, float3 y, int n);
>>>>>>>
>>>>>>> can be called as:
>>>>>>>
>>>>>>> foo(1, 2, 3, 4, 5, 6, 7);
>>>>>>>
>>>>>>
>>>>>> well its a question what to put as a mandatory.. i dont know yet,
>>>>>> but for sure thise automatic 'fitting' would be somewhat good
>>>>>>
>>>>>> some can write
>>>>>>
>>>>>> foo({1, 2, 3}, {4, 5, 6}, 7);
>>>>>>
>>>>>> and you again present anti-c philosophy
>>>>>>
>>>>>> c allows you write programs ale obfuscated c contests..in your
>>>>>> philosofy
>>>>>> you would forbide it all? forcing codes not have syttaktic shortcuts?
>>>>>>
>>>>>> i totally not agree to such philosophy
>>>>>>
>>>>>> (though its not always clear whay s good shortcut/hack c way and
>>>>>> what is not)
>>>>>>
>>>>>>
>>>>>>
>>>>>>> It's so easy to see where one argument ends and another begins!
>>>>>>> And this is the simplest possible set of arguments.
>>>>>>>
>>>>>>> Still, C has prior art here:
>>>>>>>
>>>>>>> typedef struct {float x,y,z;} float3;
>>>>>>> typedef struct {float3 a, b; int c;} T;
>>>>>>>
>>>>>>> T x = {1, 2, 3, 4, 5, 6, 7};
>>>>>>>
>>>>>>> So that would fit right in!
>>>>>>>
>>>>>>>
>>>>>>
>>>>> recent state of my rasterizer toying btw
>>>>>
>>>>> https://www.youtube.com/watch?v=xERLKVTV9s8
>>>>>
>>>>> those pices of geometry was generated by ai ...sadly when adding
>>>>> more geometry the rasterizer get slowing down ofs..and i have no
>>>>> best cpu
>>>>
>>>> Too bad you need an AI to make it for you.
>>>>
>>>
>>>
>>> you talk like medevial peasnt such your remarks here
>>>
>>> you know for some people accustomed to higher social standards you
>>> may be perceive you as a bit of a country bumpkin (sorry i dont
>>> understand this phrase its form translation, i m not quite sure what
>>> bumpkin is - i meant more like peasent, medevial villager)
>>>
>>> its not quite good to enforce you peasnty belifs on
>>> people...especially as it seems you totally dont know what youre
>>> talkin about
>>>
>>> i already told you so but it seems youre like dont get it
>>>
>>>
>>> as to rasterizer its nice to shape the pixell matter..though i need much
>>> stronger cpu, i need like 100x stronger..and it doesnt seem i would
>>> get it..though GPU in fact maybe might be so
>>>
>>> or meybe i should learn more multithreading and put it on 8 10 or 12
>>> cores... im not sure but not being experienced in this it seems that
>>> rasterisation should be quite good for multithreading - simply run 1/10
>>> of objects in the scene on 10 cores into 10 output buffers..then "add"
>>> the buffers... this depth buffers seem ideal for adding
>>>
>>> im not yet sure if it really works that way - but if it does its
>>> finally a reason to buy a desktop pc iwth many cores
>>>
>>>
>>>
>>>>>
>>>>> though modern are maybe 2-3 times faster at most i guess
>>>>
>>>
>>
>> Not really, just buy something with a half way decent GPU, or even a
>> crappy one. NVIDIA has some cheap ones. The learn how to code for it.
>
> there is no chea nvidia GPU at stores right now.. i maybe should stil
> wait if they get nootably cheaper and buy some
>
> more important gpu koding is different kind of coding... this rasterizer
> btw i coded in formal C now (as ported from old version c via c++)
> though those linker errors when i
> i call i function name which i it cant find annoys me i could say
> (in c via c++ thre eas no such thing as i remember)
Well, actually, building it from scratch is a kinda similar type of
coding. Its as if we are simulating a GPU. We can build all of the
vertex, geometry, compute, frag shaders all in C. Create the pipeline, etc.
> as to AI it so much grat i could probably name a list of 100
> (or at least 30) big advantages of it where 2-3 could be suffice to use it
Well, the AI kinds of means nobody has to buy books anymore?
> you noticed i criticize your 'peasenty' attitude but really learn what
> you talkin about becouse stating things when you got no idea what youre
> talkin about is absolutely not usenet is for
>
> usenet was always good people here focus on validating opinions and
> what you say like that: i have no idea what im talking about yet i
> will say opposite to truth is not standable here
>
> take given point you learned if something is wrong in that point
> criticize it in valid ay if you must ... or praise it if its good
> becouse this seconnd attempt is arso quite valueable i such new topic
> when people need to learn that
>
Actually, I remember an old site that had info on making everything in
C. No GPU at all. Cannot seem to find it now, it was many moons ago.
Sigh. Have you looked at the old DOOM source code?
I know how to do it, but its just too slow once you try to do some fancy
things...
Re: variadic min and max, (any some and none, cat and more)
Author: Chris M. Thomasson
Date: Mon, 26 Oct 2026 19:41
Date: Mon, 26 Oct 2026 19:41
8 lines
1892 bytes
1892 bytes
On 10/26/2026 4:30 AM, fir wrote: [...] Well, have you ever told an AI to not show you any code and/or full solutions, but act like a "book" that tries to take you through lessons? Actually, allow you to try to solve a lesson by yourself _before_ you move on to the next one?
Re: variadic min and max, (any some and none, cat and more)
Author: Chris M. Thomasson
Date: Mon, 26 Oct 2026 19:43
Date: Mon, 26 Oct 2026 19:43
42 lines
3152 bytes
3152 bytes
On 10/26/2026 9:33 AM, fir wrote: > Lawrence D’Oliveiro pisze: >> On Sun, 25 Oct 2026 15:58:58 -0700, Chris M. Thomasson wrote: >> >>> On 10/25/2026 2:56 PM, Lawrence D’Oliveiro wrote: >>>> >>>> On Sun, 25 Oct 2026 14:44:15 -0700, Chris M. Thomasson wrote: >>>> >>>>> If you want some free models to work with. check out SketchFab. >>>> >>>> Aren’t they more oriented towards 3D printing? >>> >>> Well, fir should know how to load a 3d model and light it. >> >> There are better sources of models for on-screen work. >> >> Sci-fi fan? How about this <https://trekmeshes.eu/>. >> > those are prioprietary more or less > > ai generates quite nice models imo > > https://www.youtube.com/watch?v=PeTMNf4Z8q4 > > and whats great there are like i get the legal rights to them > at least in such extnt i can uise them - which is great > > becouse even if tehre are free models in the net i dont like the > dependencies of such type > > and here is liek i get rights to this stations and ships > > possibly not agressive that someone can generate the same or close and > he has also rights to thuis and its also very good as i dont like > agresive copyrights > > but startrek is ok and i could eventually even download and load thse > models just tos see how it look Getting your engine to load up other peoples models correctly is not exactly "easy". Some of the models even have their own shaders. Then you need to learn about the bones, and how to animate them.
Re: variadic min and max, (any some and none, cat and more)
Author: Chris M. Thomasson
Date: Mon, 26 Oct 2026 19:47
Date: Mon, 26 Oct 2026 19:47
12 lines
2198 bytes
2198 bytes
On 10/26/2026 5:51 AM, fir wrote: [...] Hove you ever read the Tommyknockers by Stephen King? The damn aliens started to give the people of Haven the knowledge on how to build very interesting things. But, the people did not know anything about the underlying processes. They just blindly build them. But did not know how they worked at all, or the tech and reasoning behind it. So building a 3d renderer from pure scratch can be a good thing. Just try to refrain from the AI doing all the work for you. damn.
Re: This is rich... (Was: variadic min and max, (any some and none, cat and more))
Author: Chris M. Thomasson
Date: Mon, 26 Oct 2026 19:48
Date: Mon, 26 Oct 2026 19:48
9 lines
1669 bytes
1669 bytes
On 10/26/2026 10:47 AM, Kenny McCormack wrote: > In article <11bnvi2$oo6k$1@dont-email.me>, "fir" wrote: > ... >>> so many people dont get basics and talk crazy things > > This is rich, coming from "fir"... > Yikes!
Re: This is rich... (Was: variadic min and max, (any some and none, cat and more))
Author: Richard Harnden
Date: Mon, 26 Oct 2026 20:05
Date: Mon, 26 Oct 2026 20:05
13 lines
1806 bytes
1806 bytes
On 26/10/2026 19:48, Chris M. Thomasson wrote: > On 10/26/2026 10:47 AM, Kenny McCormack wrote: >> In article <11bnvi2$oo6k$1@dont-email.me>, "fir" wrote: >> ... >>>> so many people dont get basics and talk crazy things >> >> This is rich, coming from "fir"... >> > > Yikes! ITYM: Yeiks :)
Re: variadic min and max, (any some and none, cat and more)
Author: Rosario19
Date: Sat, 31 Oct 2026 16:33
Date: Sat, 31 Oct 2026 16:33
47 lines
2282 bytes
2282 bytes
On Sun, 25 Oct 2026 04:24:26 +0000, Richard Harnden wrote:
>On 23/10/2026 06:44, fir wrote:
>> when thinkong on variadic functions not much come to mind but
>> only recently i noticed min or max would be good for variadic
>>
>> the ai wrote me such variadic min
>
>I don't think that I'd bother with stdarg at all.
>
>Just use a string of ints ...
>
>int min(const int *n)
>{
> int m = INT_MAX;
>
> while ( *n )
> {
> if ( *n < m ) m = *n;
>
> n++;
> }
>
> return m;
>}
>
>> int a=Min(4,10,3,7,-2); // -2
>
>int a = min((int[]){10,3,7,-2}));
in this way can not be used 0, in the 0 terminated list of integers...
I think would be better opertate in the INT_MAX terminate list of
integers (so the range would be INT_MIN..(INT_MAX-1)):
int min(int *n)
{int m=INT_MAX;
while ( *n!=INT_MAX )
{if ( *n < m ) m = *n;
n++;
}
return m;
}
this would be better because allow to use 0 too at cost to not use the
INT_MAX value
Re: variadic min and max, (any some and none, cat and more)
Author: fir
Date: Sat, 31 Oct 2026 17:53
Date: Sat, 31 Oct 2026 17:53
57 lines
2898 bytes
2898 bytes
Rosario19 pisze:
> On Sun, 25 Oct 2026 04:24:26 +0000, Richard Harnden wrote:
>> On 23/10/2026 06:44, fir wrote:
>>> when thinkong on variadic functions not much come to mind but
>>> only recently i noticed min or max would be good for variadic
>>>
>>> the ai wrote me such variadic min
>>
>> I don't think that I'd bother with stdarg at all.
>>
>> Just use a string of ints ...
>>
>> int min(const int *n)
>> {
>> int m = INT_MAX;
>>
>> while ( *n )
>> {
>> if ( *n < m ) m = *n;
>>
>> n++;
>> }
>>
>> return m;
>> }
>>
>>> int a=Min(4,10,3,7,-2); // -2
>>
>> int a = min((int[]){10,3,7,-2}));
>
> in this way can not be used 0, in the 0 terminated list of integers...
>
> I think would be better opertate in the INT_MAX terminate list of
> integers (so the range would be INT_MIN..(INT_MAX-1)):
>
> int min(int *n)
> {int m=INT_MAX;
>
> while ( *n!=INT_MAX )
> {if ( *n < m ) m = *n;
> n++;
> }
> return m;
> }
>
> this would be better because allow to use 0 too at cost to not use the
> INT_MAX value
>
thats quite good remark..interestingly i didnt thought of that thing
(maybe becouse i nevef needed that, coz i dont much lik ethose
things that have mark of end, but if some ould do indeed the value_max
is imo better to use
vaguelly i remember writing in commodore 64 assembly could have some
convention (FF or FFFF) but i dont exactly remember
Re: variadic min and max, (any some and none, cat and more)
Author: Lawrence D’Oliveiro
Date: Sun, 01 Nov 2026 02:29
Date: Sun, 01 Nov 2026 02:29
9 lines
1638 bytes
1638 bytes
On Sat, 31 Oct 2026 17:33:24 +0100, Rosario19 wrote: > I think would be better opertate in the INT_MAX terminate list of > integers (so the range would be INT_MIN..(INT_MAX-1)): min() should terminate on hitting INT_MIN, because any subsequent arguments would make no difference to the result. Similarly, max() should terminate on hitting INT_MAX.
Re: variadic min and max, (any some and none, cat and more)
Author: Tim Rentsch
Date: Mon, 30 Nov 2026 07:08
Date: Mon, 30 Nov 2026 07:08
50 lines
3076 bytes
3076 bytes
bartc <bc@freeuk.com> writes: > On 24/10/2026 15:17, Tim Rentsch wrote: > >> bartc <bc@freeuk.com> writes: >> >> [discussing how to implement min() and max() functions] >> >>> [...] >>> I never did an implementation, but the elements would be assembled >>> into a buffer, not pushed, and a pointer to that buffer passed as >>> well as the length. (My scheme would have been syntactic sugar >>> for slices, which carry a length.) >>> >>> Of course this is only where all variadic elements are the same >>> type. Mixed types would need to use the existing less safe >>> variadic scheme. >> >> First let's take a stab at stating the problem: >> >> 1. Define min() and max() variadic functions or macros ... >> >> 2. That accept any (reasonable) number of arguments ... >> >> 3. Which can be any combination of suitable types ... >> >> 4. Including standard integer types and real floating types ... >> >> 5. Evaluating each argument exactly once ... >> >> 6. Producing a result having a type suitable to the arguments ... >> >> 7. And does something sensible when arguments are of mixed types. > > I thought (3) implied mixed types, so that it would work even in that > case. (Maybe 'suitable' needs to be defined.) Right. The question is what happens when the types involved are an unusual combination, such as an unsigned long long and a float. > But (7) suggests that would be an error. No, it doesn't. "Something sensible" might be a run-time error, or just as easily "something sensible" might have a well defined rule that produces a plausible result of a plausible type. > What about types such as pointers (where comparisons can work), or > structs (where they don't)? This question is silly.
Re: variadic min and max, (any some and none, cat and more)
Author: Bonita Montero
Date: Mon, 30 Nov 2026 16:13
Date: Mon, 30 Nov 2026 16:13
21 lines
1810 bytes
1810 bytes
C++ can do that better:
template<typename Only>
constexpr Only max( const Only &only )
{
return only;
}
template<typename First, typename Second, typename ... After>
constexpr common_type_t<First, Second, After ...> max( const First
&first, const Second &second, const After &... after )
{
using common = common_type_t<First, Second, After ...>;
common larger = first > second ? first : second;
if constexpr( sizeof ...( after ) != 0 )
return max( larger, after ... );
else
return larger;
}
Re: variadic min and max, (any some and none, cat and more)
Author: Lawrence D’Oliveiro
Date: Mon, 30 Nov 2026 18:40
Date: Mon, 30 Nov 2026 18:40
32 lines
2128 bytes
2128 bytes
On Mon, 30 Nov 2026 17:13:21 +0100, Bonita Montero wrote:
> C++ can do that better:
>
> template<typename Only>
> constexpr Only max( const Only &only )
> {
> return only;
> }
>
> template<typename First, typename Second, typename ... After>
> constexpr common_type_t<First, Second, After ...> max( const First
> &first, const Second &second, const After &... after )
> {
> using common = common_type_t<First, Second, After ...>;
> common larger = first > second ? first : second;
> if constexpr( sizeof ...( after ) != 0 )
> return max( larger, after ... );
> else
> return larger;
> }
That takes a lot of code, and it still cannot cope with
dynamically-generated lists:
Python 3.14.10 (main, Oct 26 2026, 15:12:11) [GCC 16.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> max(2, 3, 5)
5
>>> args = [2, 3, 5]
>>> max(*args)
5
Re: variadic min and max, (any some and none, cat and more)
Author: Bonita Montero
Date: Mon, 30 Nov 2026 18:44
Date: Mon, 30 Nov 2026 18:44
31 lines
2283 bytes
2283 bytes
Am 30.11.2026 um 19:40 schrieb Lawrence D’Oliveiro:
> On Mon, 30 Nov 2026 17:13:21 +0100, Bonita Montero wrote:
>> C++ can do that better:
>>
>> template<typename Only>
>> constexpr Only max( const Only &only )
>> {
>> return only;
>> }
>>
>> template<typename First, typename Second, typename ... After>
>> constexpr common_type_t<First, Second, After ...> max( const First
>> &first, const Second &second, const After &... after )
>> {
>> using common = common_type_t<First, Second, After ...>;
>> common larger = first > second ? first : second;
>> if constexpr( sizeof ...( after ) != 0 )
>> return max( larger, after ... );
>> else
>> return larger;
>> }
> That takes a lot of code, and it still cannot cope with
> dynamically-generated lists:
It's for sure more flexible since it can handle more variations of
compatible types and it's for sure much fasger.
Re: variadic min and max, (any some and none, cat and more)
Author: Lawrence D’Oliveiro
Date: Mon, 30 Nov 2026 18:49
Date: Mon, 30 Nov 2026 18:49
23 lines
1963 bytes
1963 bytes
On Mon, 30 Nov 2026 19:44:50 +0100, Bonita Montero wrote:
> Am 30.11.2026 um 19:40 schrieb Lawrence D’Oliveiro:
>>
>> Python 3.14.10 (main, Oct 26 2026, 15:12:11) [GCC 16.2.0] on linux
>> Type "help", "copyright", "credits" or "license" for more information.
>> >>> max(2, 3, 5)
>> 5
>> >>> args = [2, 3, 5]
>> >>> max(*args)
>> 5
>
> It's for sure more flexible since it can handle more variations of
> compatible types and it's for sure much fasger.
You betcha:
>>> max("red", "green", "blue")
'red'
>>> max(["red"], ["red", "green"], ["blue"])
['red', 'green']
Anything that has an ordering defined will work.
Re: variadic min and max, (any some and none, cat and more)
Author: Bonita Montero
Date: Mon, 30 Nov 2026 19:47
Date: Mon, 30 Nov 2026 19:47
18 lines
2012 bytes
2012 bytes
Am 30.11.2026 um 19:49 schrieb Lawrence D’Oliveiro:
> On Mon, 30 Nov 2026 19:44:50 +0100, Bonita Montero wrote:
>> It's for sure more flexible since it can handle more variations of
>> compatible types and it's for sure much fasger.
> You betcha:
>
> >>> max("red", "green", "blue")
> 'red'
> >>> max(["red"], ["red", "green"], ["blue"])
> ['red', 'green']
>
> Anything that has an ordering defined will work.
In C++ you can write your own conversion to supply compatible types.
Re: variadic min and max, (any some and none, cat and more)
Author: Lawrence D’Oliveiro
Date: Mon, 30 Nov 2026 21:34
Date: Mon, 30 Nov 2026 21:34
27 lines
2340 bytes
2340 bytes
On Mon, 30 Nov 2026 20:47:38 +0100, Bonita Montero wrote:
> Am 30.11.2026 um 19:49 schrieb Lawrence D’Oliveiro:
>
>> On Mon, 30 Nov 2026 19:44:50 +0100, Bonita Montero wrote:
>
>>> It's for sure more flexible since it can handle more variations of
>>> compatible types and it's for sure much fasger.
>
>> You betcha:
>>
>> >>> max("red", "green", "blue")
>> 'red'
>> >>> max(["red"], ["red", "green"], ["blue"])
>> ['red', 'green']
>>
>> Anything that has an ordering defined will work.
>
> In C++ you can write your own conversion to supply compatible types.
Python does custom operator overloads, too. And multiple inheritance.
And its core definition still ends up being only a small fraction of
the size of C++.
And unlike C++, and almost like Algol 68, it can do things that look
like custom operators, too
<https://gitlab.com/ldo/python_topics_notebooks/-/blob/master/Defining%20(Almost)%20Custom%20Operators.ipynb>.
Re: variadic min and max, (any some and none, cat and more)
Author: Janis Papanagnou
Date: Mon, 30 Nov 2026 22:50
Date: Mon, 30 Nov 2026 22:50
34 lines
2846 bytes
2846 bytes
On 2026-11-30 22:34, Lawrence D’Oliveiro wrote: > [...] > > And unlike C++, and almost like Algol 68, it can do things that look > like custom operators, too What does that mean? - Behind your link quoted below we can read: "Python lets you add custom overloads for its built-in operators, but it doesn’t let you create entirely new operators." Overloading existing operators is also possible in C++, so what's the actual difference (in Python)? - It seems the only difference is to be able to provide [clumsy] _named_ operators that (compared to ordinary functions) just avoids the necessity for parentheses. The method seems convoluted, though, and the syntax is very crude, IMO. The "final score" (on the linked page) is the Python example for the cross product (and requiring additional helper functions) with an operator expression like v1 .cross* v2 .cross* v3 which would in Algol 68 (since you mentioned it) probably be more something like either (with named operator 'X'), say, v1 X v2 X v3 or (with symbolic operator), say, v1 * v2 * v3 or any other allowed operator symbol(-sequence). Take your choice. Concerning the C++ case I don't see that Python would add anything worthwhile here. YMMV. Janis > <https://gitlab.com/ldo/python_topics_notebooks/-/blob/master/Defining%20(Almost)%20Custom%20Operators.ipynb>.
Re: variadic min and max, (any some and none, cat and more)
Author: Bonita Montero
Date: Tue, 01 Dec 2026 05:19
Date: Tue, 01 Dec 2026 05:19
9 lines
1861 bytes
1861 bytes
Am 30.11.2026 um 22:34 schrieb Lawrence D’Oliveiro: > Python does custom operator overloads, too. And multiple inheritance. > And its core definition still ends up being only a small fraction of > the size of C++. https://benchmarksgame-team.pages.debian.net/benchmarksgame/fastest/python3-gpp.html
Re: variadic min and max, (any some and none, cat and more)
Author: Lawrence D’Oliveiro
Date: Tue, 01 Dec 2026 05:50
Date: Tue, 01 Dec 2026 05:50
13 lines
1920 bytes
1920 bytes
On Tue, 1 Dec 2026 06:19:11 +0100, Bonita Montero wrote: > Am 30.11.2026 um 22:34 schrieb Lawrence D’Oliveiro: > >> Python does custom operator overloads, too. And multiple >> inheritance. And its core definition still ends up being only a >> small fraction of the size of C++. > > https://benchmarksgame-team.pages.debian.net/benchmarksgame/fastest/python3-gpp.html Page wouldn’t come up for me. Must be running a web server written in C++ ...
Re: variadic min and max, (any some and none, cat and more)
Author: David Brown
Date: Tue, 01 Dec 2026 09:31
Date: Tue, 01 Dec 2026 09:31
107 lines
4611 bytes
4611 bytes
On 30/11/2026 22:34, Lawrence D’Oliveiro wrote:
> On Mon, 30 Nov 2026 20:47:38 +0100, Bonita Montero wrote:
>
>> Am 30.11.2026 um 19:49 schrieb Lawrence D’Oliveiro:
>>
>>> On Mon, 30 Nov 2026 19:44:50 +0100, Bonita Montero wrote:
>>
>>>> It's for sure more flexible since it can handle more variations of
>>>> compatible types and it's for sure much fasger.
>>
>>> You betcha:
>>>
>>> >>> max("red", "green", "blue")
>>> 'red'
>>> >>> max(["red"], ["red", "green"], ["blue"])
>>> ['red', 'green']
>>>
>>> Anything that has an ordering defined will work.
>>
>> In C++ you can write your own conversion to supply compatible types.
>
> Python does custom operator overloads, too. And multiple inheritance.
> And its core definition still ends up being only a small fraction of
> the size of C++.
>
> And unlike C++, and almost like Algol 68, it can do things that look
> like custom operators, too
> <https://gitlab.com/ldo/python_topics_notebooks/-/blob/master/Defining%20(Almost)%20Custom%20Operators.ipynb>.
You can do that just as well in C++ as in Python.
A 3D vector type in C++ is simple :
template<typename T>
struct Vector {
T x, y, z;
};
Vector v1 { 2, 3, 4 };
Vector v2 { 5, 4, 3 };
Making operator overloads for multiplication like your Python example,
with pairwise multiplication and multiplication by a scalar is standard
stuff :
template<typename T>
constexpr auto operator * (Vector<T> a, Vector<T> b) {
return Vector(a.x * b.x, a.y * b.y, a.z * b.z);
}
template<typename T>
constexpr auto operator * (Vector<T> a, T b) {
return Vector(a.x * b, a.y * b, a.z * b);
}
Vector v1_times_v2 = v1 * v2;
Vector v1_times_2 = v1 * 2;
Making an additional named operator is just a matter of a simple wrapper
struct whose type is used to change the meaning of operators. Then you
have a singleton type that is used to generate the wrapper.
template<typename T>
struct Crosser_wrapper : Vector<T> { };
struct Cross { };
constexpr Cross cross;
template<typename T>
constexpr auto operator * (const Vector<T> & a, Cross) {
return Crosser_wrapper(a);
}
template<typename T>
constexpr auto operator * (Crosser_wrapper<T> a,
Vector<T> b) {
return Vector(a.y * b.z - a.z * b.y,
a.z * b.x - a.x * b.z,
a.x * b.y - a.y * b.x);
}
Vector v1cross = v1 *cross* v2;
Note that this is all zero-cost at runtime. No extra space needed, no
extra function calls generated, no need for the "cross" bit to hold
information or track references to the vector data, etc. It's just type
manipulation to change which function is called.
And if you want to, you can also do :
#define 𝘅 *cross*
Vector v1cross2 = v1 𝘅 v2;
Nice, to read, but hard to type.
(I am not saying that this is a good idea in real code, but it
demonstrates the technique. Use it if you like it. If anyone wants to
discuss this in more detail, look at more generalisations, make it
safer, etc., then a new thread in comp.lang.c++ would be more appropriate.)
Re: variadic min and max, (any some and none, cat and more)
Author: bartc
Date: Tue, 01 Dec 2026 12:11
Date: Tue, 01 Dec 2026 12:11
144 lines
6096 bytes
6096 bytes
On 01/12/2026 09:31, David Brown wrote:
> On 30/11/2026 22:34, Lawrence D’Oliveiro wrote:
>> On Mon, 30 Nov 2026 20:47:38 +0100, Bonita Montero wrote:
>>
>>> Am 30.11.2026 um 19:49 schrieb Lawrence D’Oliveiro:
>>>
>>>> On Mon, 30 Nov 2026 19:44:50 +0100, Bonita Montero wrote:
>>>
>>>>> It's for sure more flexible since it can handle more variations of
>>>>> compatible types and it's for sure much fasger.
>>>
>>>> You betcha:
>>>>
>>>> >>> max("red", "green", "blue")
>>>> 'red'
>>>> >>> max(["red"], ["red", "green"], ["blue"])
>>>> ['red', 'green']
>>>>
>>>> Anything that has an ordering defined will work.
>>>
>>> In C++ you can write your own conversion to supply compatible types.
>>
>> Python does custom operator overloads, too. And multiple inheritance.
>> And its core definition still ends up being only a small fraction of
>> the size of C++.
>>
>> And unlike C++, and almost like Algol 68, it can do things that look
>> like custom operators, too
>> <https://gitlab.com/ldo/python_topics_notebooks/-/blob/master/
>> Defining%20(Almost)%20Custom%20Operators.ipynb>.
>
> You can do that just as well in C++ as in Python.
>
> A 3D vector type in C++ is simple :
>
> template<typename T>
> struct Vector {
> T x, y, z;
> };
>
> Vector v1 { 2, 3, 4 };
> Vector v2 { 5, 4, 3 };
>
>
>
> Making operator overloads for multiplication like your Python example,
> with pairwise multiplication and multiplication by a scalar is standard
> stuff :
>
> template<typename T>
> constexpr auto operator * (Vector<T> a, Vector<T> b) {
> return Vector(a.x * b.x, a.y * b.y, a.z * b.z);
> }
>
> template<typename T>
> constexpr auto operator * (Vector<T> a, T b) {
> return Vector(a.x * b, a.y * b, a.z * b);
> }
>
> Vector v1_times_v2 = v1 * v2;
> Vector v1_times_2 = v1 * 2;
>
>
> Making an additional named operator is just a matter of a simple wrapper
> struct whose type is used to change the meaning of operators. Then you
> have a singleton type that is used to generate the wrapper.
>
>
> template<typename T>
> struct Crosser_wrapper : Vector<T> { };
>
> struct Cross { };
> constexpr Cross cross;
>
> template<typename T>
> constexpr auto operator * (const Vector<T> & a, Cross) {
> return Crosser_wrapper(a);
> }
>
> template<typename T>
> constexpr auto operator * (Crosser_wrapper<T> a,
> Vector<T> b) {
> return Vector(a.y * b.z - a.z * b.y,
> a.z * b.x - a.x * b.z,
> a.x * b.y - a.y * b.x);
> }
>
> Vector v1cross = v1 *cross* v2;
>
>
> Note that this is all zero-cost at runtime. No extra space needed, no
> extra function calls generated, no need for the "cross" bit to hold
> information or track references to the vector data, etc. It's just type
> manipulation to change which function is called.
>
> And if you want to, you can also do :
>
> #define 𝘅 *cross*
>
> Vector v1cross2 = v1 𝘅 v2;
>
> Nice, to read, but hard to type.
>
>
> (I am not saying that this is a good idea in real code, but it
> demonstrates the technique. Use it if you like it. If anyone wants to
> discuss this in more detail, look at more generalisations, make it
> safer, etc., then a new thread in comp.lang.c++ would be more appropriate.)
>
Here is what I was able to write, using one of my earliest scripting
languages (early 90s):
v1 := (2, 3, 4)
v2 := (5, 4, 3)
println v1 * v2 # vector product
println v1 iand v2 # dot product
println v1 * 5.1 # scalar product
println (v1 + v2) / 2
(I can't remember why 'iand' - bitwise and - was used for a
dot-product.) Output is:
(-7.00, 14.00, -7.00)
34.000000
(10.20, 15.30, 20.40)
(3.50, 3.50, 3.50)
Some more:
v := (100, 0)
m := rotatematrix(15°, "Z")
println v * (m * m) # rotate 30 deg ac/w
(Shows (86.60, 50.00, 0.00).)
I found it was simplest just to build-in whatever is needed (this
language was used with my 3D graphics app). No imports or libraries are
needed, and every user had the same abilities out-of-the-box.
Re: variadic min and max, (any some and none, cat and more)
Author: David Brown
Date: Tue, 01 Dec 2026 13:53
Date: Tue, 01 Dec 2026 13:53
164 lines
7519 bytes
7519 bytes
On 01/12/2026 13:11, bartc wrote:
> On 01/12/2026 09:31, David Brown wrote:
>> On 30/11/2026 22:34, Lawrence D’Oliveiro wrote:
>>> On Mon, 30 Nov 2026 20:47:38 +0100, Bonita Montero wrote:
>>>
>>>> Am 30.11.2026 um 19:49 schrieb Lawrence D’Oliveiro:
>>>>
>>>>> On Mon, 30 Nov 2026 19:44:50 +0100, Bonita Montero wrote:
>>>>
>>>>>> It's for sure more flexible since it can handle more variations of
>>>>>> compatible types and it's for sure much fasger.
>>>>
>>>>> You betcha:
>>>>>
>>>>> >>> max("red", "green", "blue")
>>>>> 'red'
>>>>> >>> max(["red"], ["red", "green"], ["blue"])
>>>>> ['red', 'green']
>>>>>
>>>>> Anything that has an ordering defined will work.
>>>>
>>>> In C++ you can write your own conversion to supply compatible types.
>>>
>>> Python does custom operator overloads, too. And multiple inheritance.
>>> And its core definition still ends up being only a small fraction of
>>> the size of C++.
>>>
>>> And unlike C++, and almost like Algol 68, it can do things that look
>>> like custom operators, too
>>> <https://gitlab.com/ldo/python_topics_notebooks/-/blob/master/
>>> Defining%20(Almost)%20Custom%20Operators.ipynb>.
>>
>> You can do that just as well in C++ as in Python.
>>
>> A 3D vector type in C++ is simple :
>>
>> template<typename T>
>> struct Vector {
>> T x, y, z;
>> };
>>
>> Vector v1 { 2, 3, 4 };
>> Vector v2 { 5, 4, 3 };
>>
>>
>>
>> Making operator overloads for multiplication like your Python example,
>> with pairwise multiplication and multiplication by a scalar is
>> standard stuff :
>>
>> template<typename T>
>> constexpr auto operator * (Vector<T> a, Vector<T> b) {
>> return Vector(a.x * b.x, a.y * b.y, a.z * b.z);
>> }
>>
>> template<typename T>
>> constexpr auto operator * (Vector<T> a, T b) {
>> return Vector(a.x * b, a.y * b, a.z * b);
>> }
>>
>> Vector v1_times_v2 = v1 * v2;
>> Vector v1_times_2 = v1 * 2;
>>
>>
>> Making an additional named operator is just a matter of a simple
>> wrapper struct whose type is used to change the meaning of operators.
>> Then you have a singleton type that is used to generate the wrapper.
>>
>>
>> template<typename T>
>> struct Crosser_wrapper : Vector<T> { };
>>
>> struct Cross { };
>> constexpr Cross cross;
>>
>> template<typename T>
>> constexpr auto operator * (const Vector<T> & a, Cross) {
>> return Crosser_wrapper(a);
>> }
>>
>> template<typename T>
>> constexpr auto operator * (Crosser_wrapper<T> a,
>> Vector<T> b) {
>> return Vector(a.y * b.z - a.z * b.y,
>> a.z * b.x - a.x * b.z,
>> a.x * b.y - a.y * b.x);
>> }
>>
>> Vector v1cross = v1 *cross* v2;
>>
>>
>> Note that this is all zero-cost at runtime. No extra space needed, no
>> extra function calls generated, no need for the "cross" bit to hold
>> information or track references to the vector data, etc. It's just
>> type manipulation to change which function is called.
>>
>> And if you want to, you can also do :
>>
>> #define 𝘅 *cross*
>>
>> Vector v1cross2 = v1 𝘅 v2;
>>
>> Nice, to read, but hard to type.
>>
>
>
>>
>> (I am not saying that this is a good idea in real code, but it
>> demonstrates the technique. Use it if you like it. If anyone wants
>> to discuss this in more detail, look at more generalisations, make it
>> safer, etc., then a new thread in comp.lang.c++ would be more
>> appropriate.)
>>
>
> Here is what I was able to write, using one of my earliest scripting
> languages (early 90s):
>
> v1 := (2, 3, 4)
> v2 := (5, 4, 3)
>
> println v1 * v2 # vector product
> println v1 iand v2 # dot product
> println v1 * 5.1 # scalar product
> println (v1 + v2) / 2
>
> (I can't remember why 'iand' - bitwise and - was used for a dot-
> product.) Output is:
>
> (-7.00, 14.00, -7.00)
> 34.000000
> (10.20, 15.30, 20.40)
> (3.50, 3.50, 3.50)
>
> Some more:
>
> v := (100, 0)
> m := rotatematrix(15°, "Z")
> println v * (m * m) # rotate 30 deg ac/w
>
> (Shows (86.60, 50.00, 0.00).)
>
> I found it was simplest just to build-in whatever is needed (this
> language was used with my 3D graphics app). No imports or libraries are
> needed, and every user had the same abilities out-of-the-box.
>
>
When you have a domain-specific language, and full control of the
language, then built-ins can be easier. The point of techniques like
this, whether in Python or C++, is that the language and toolchain only
needs to support the technique. Then the individual users or library
vendors can use it for any operations and any types. If someone wants
to make a type that supports 8 x 8 matrices over complex doubles with a
binary exponential operator, and write "matrix A = B *pow* C;", then
they can do that with pretty much identical code as this. Well, they'd
have to write code for the exponential operator in question, and good
luck doing that efficiently manner while keeping numeric stability. But
the wrapping code to support the syntax is straightforward.
Some other languages, like Haskell, make it easier to write your own
operators and also let you use symbols for them. C++ lets you write
"rotatematrix(15_deg, "Z")", but not "15°". (You'd have to find a
Unicode letter that looks like a degree symbol.)
Re: variadic min and max, (any some and none, cat and more)
Author: Bonita Montero
Date: Tue, 01 Dec 2026 15:33
Date: Tue, 01 Dec 2026 15:33
12 lines
2117 bytes
2117 bytes
Am 01.12.2026 um 14:53 schrieb David Brown:
> Some other languages, like Haskell, make it easier to write your own
> operators and also let you use symbols for them. C++ lets you write
> "rotatematrix(15_deg, "Z")", but not "15°". (You'd have to find a
> Unicode letter that looks like a degree symbol.)
This is sth. similar in C++:
complex<double> operator ""_degree( long double angle )
{
return complex<double>( sin( angle ), cos( angle ) );
}
Re: variadic min and max, (any some and none, cat and more)
Author: David Brown
Date: Tue, 01 Dec 2026 16:06
Date: Tue, 01 Dec 2026 16:06
16 lines
2216 bytes
2216 bytes
On 01/12/2026 16:33, Bonita Montero wrote:
> Am 01.12.2026 um 14:53 schrieb David Brown:
>
>> Some other languages, like Haskell, make it easier to write your own
>> operators and also let you use symbols for them. C++ lets you write
>> "rotatematrix(15_deg, "Z")", but not "15°". (You'd have to find a
>> Unicode letter that looks like a degree symbol.)
> This is sth. similar in C++:
>
> complex<double> operator ""_degree( long double angle )
> {
> return complex<double>( sin( angle ), cos( angle ) );
> }
That's what I said.
Re: variadic min and max, (any some and none, cat and more)
Author: Ross Finlayson
Date: Tue, 01 Dec 2026 16:30
Date: Tue, 01 Dec 2026 16:30
204 lines
8829 bytes
8829 bytes
On 12/01/2026 05:53 AM, David Brown wrote:
> On 01/12/2026 13:11, bartc wrote:
>> On 01/12/2026 09:31, David Brown wrote:
>>> On 30/11/2026 22:34, Lawrence D’Oliveiro wrote:
>>>> On Mon, 30 Nov 2026 20:47:38 +0100, Bonita Montero wrote:
>>>>
>>>>> Am 30.11.2026 um 19:49 schrieb Lawrence D’Oliveiro:
>>>>>
>>>>>> On Mon, 30 Nov 2026 19:44:50 +0100, Bonita Montero wrote:
>>>>>
>>>>>>> It's for sure more flexible since it can handle more variations of
>>>>>>> compatible types and it's for sure much fasger.
>>>>>
>>>>>> You betcha:
>>>>>>
>>>>>> >>> max("red", "green", "blue")
>>>>>> 'red'
>>>>>> >>> max(["red"], ["red", "green"], ["blue"])
>>>>>> ['red', 'green']
>>>>>>
>>>>>> Anything that has an ordering defined will work.
>>>>>
>>>>> In C++ you can write your own conversion to supply compatible types.
>>>>
>>>> Python does custom operator overloads, too. And multiple inheritance.
>>>> And its core definition still ends up being only a small fraction of
>>>> the size of C++.
>>>>
>>>> And unlike C++, and almost like Algol 68, it can do things that look
>>>> like custom operators, too
>>>> <https://gitlab.com/ldo/python_topics_notebooks/-/blob/master/
>>>> Defining%20(Almost)%20Custom%20Operators.ipynb>.
>>>
>>> You can do that just as well in C++ as in Python.
>>>
>>> A 3D vector type in C++ is simple :
>>>
>>> template<typename T>
>>> struct Vector {
>>> T x, y, z;
>>> };
>>>
>>> Vector v1 { 2, 3, 4 };
>>> Vector v2 { 5, 4, 3 };
>>>
>>>
>>>
>>> Making operator overloads for multiplication like your Python
>>> example, with pairwise multiplication and multiplication by a scalar
>>> is standard stuff :
>>>
>>> template<typename T>
>>> constexpr auto operator * (Vector<T> a, Vector<T> b) {
>>> return Vector(a.x * b.x, a.y * b.y, a.z * b.z);
>>> }
>>>
>>> template<typename T>
>>> constexpr auto operator * (Vector<T> a, T b) {
>>> return Vector(a.x * b, a.y * b, a.z * b);
>>> }
>>>
>>> Vector v1_times_v2 = v1 * v2;
>>> Vector v1_times_2 = v1 * 2;
>>>
>>>
>>> Making an additional named operator is just a matter of a simple
>>> wrapper struct whose type is used to change the meaning of operators.
>>> Then you have a singleton type that is used to generate the wrapper.
>>>
>>>
>>> template<typename T>
>>> struct Crosser_wrapper : Vector<T> { };
>>>
>>> struct Cross { };
>>> constexpr Cross cross;
>>>
>>> template<typename T>
>>> constexpr auto operator * (const Vector<T> & a, Cross) {
>>> return Crosser_wrapper(a);
>>> }
>>>
>>> template<typename T>
>>> constexpr auto operator * (Crosser_wrapper<T> a,
>>> Vector<T> b) {
>>> return Vector(a.y * b.z - a.z * b.y,
>>> a.z * b.x - a.x * b.z,
>>> a.x * b.y - a.y * b.x);
>>> }
>>>
>>> Vector v1cross = v1 *cross* v2;
>>>
>>>
>>> Note that this is all zero-cost at runtime. No extra space needed,
>>> no extra function calls generated, no need for the "cross" bit to
>>> hold information or track references to the vector data, etc. It's
>>> just type manipulation to change which function is called.
>>>
>>> And if you want to, you can also do :
>>>
>>> #define 𝘅 *cross*
>>>
>>> Vector v1cross2 = v1 𝘅 v2;
>>>
>>> Nice, to read, but hard to type.
>>>
>>
>>
>>>
>>> (I am not saying that this is a good idea in real code, but it
>>> demonstrates the technique. Use it if you like it. If anyone wants
>>> to discuss this in more detail, look at more generalisations, make it
>>> safer, etc., then a new thread in comp.lang.c++ would be more
>>> appropriate.)
>>>
>>
>> Here is what I was able to write, using one of my earliest scripting
>> languages (early 90s):
>>
>> v1 := (2, 3, 4)
>> v2 := (5, 4, 3)
>>
>> println v1 * v2 # vector product
>> println v1 iand v2 # dot product
>> println v1 * 5.1 # scalar product
>> println (v1 + v2) / 2
>>
>> (I can't remember why 'iand' - bitwise and - was used for a dot-
>> product.) Output is:
>>
>> (-7.00, 14.00, -7.00)
>> 34.000000
>> (10.20, 15.30, 20.40)
>> (3.50, 3.50, 3.50)
>>
>> Some more:
>>
>> v := (100, 0)
>> m := rotatematrix(15°, "Z")
>> println v * (m * m) # rotate 30 deg ac/w
>>
>> (Shows (86.60, 50.00, 0.00).)
>>
>> I found it was simplest just to build-in whatever is needed (this
>> language was used with my 3D graphics app). No imports or libraries
>> are needed, and every user had the same abilities out-of-the-box.
>>
>>
>
> When you have a domain-specific language, and full control of the
> language, then built-ins can be easier. The point of techniques like
> this, whether in Python or C++, is that the language and toolchain only
> needs to support the technique. Then the individual users or library
> vendors can use it for any operations and any types. If someone wants
> to make a type that supports 8 x 8 matrices over complex doubles with a
> binary exponential operator, and write "matrix A = B *pow* C;", then
> they can do that with pretty much identical code as this. Well, they'd
> have to write code for the exponential operator in question, and good
> luck doing that efficiently manner while keeping numeric stability. But
> the wrapping code to support the syntax is straightforward.
>
> Some other languages, like Haskell, make it easier to write your own
> operators and also let you use symbols for them. C++ lets you write
> "rotatematrix(15_deg, "Z")", but not "15°". (You'd have to find a
> Unicode letter that looks like a degree symbol.)
>
It's all "algebraizations" of "arithmetizations" eventually
"geometrizations", or vice-versa, then for example as with regards
"lambda-calculus" and "pi-calculus", the "expressitivity".
"Latin1" then its subset "ASCII" is usually considered "the limits
of the letters of the source language": we have keyboards for that.
Of course Unicode is a great account and many languages have
Unicode as allowed in identifiers.
It's like Madonna says, "express yourself".
("Mouseketeers", ..., it's a small world.)
"Give him something he can feel."
Language: it's got expressitivity in it.
I don't know anywhere where digits begin identifiers.
(... In C-like languages.)
The expressitivity and interpretability then have
that "language standards" define "interpretability",
then that's called "defined".
A "superset of C" like "OpenMP", or for example
"co_await" and "co_return" after being "a superset of C++",
it's just a wider language, where the narrower yet
remains defined.
Natural "arithmetizations" still make for what "operator overloading"
gives: just need to have a model of objects that behave their
relations just like regular integers, and the values of those
objects are integers (and so is their type).
Re: variadic min and max, (any some and none, cat and more)
Author: bartc
Date: Tue, 01 Dec 2026 17:48
Date: Tue, 01 Dec 2026 17:48
45 lines
3575 bytes
3575 bytes
On 01/12/2026 13:53, David Brown wrote:
> On 01/12/2026 13:11, bartc wrote:
>> Some more:
>>
>> v := (100, 0)
>> m := rotatematrix(15°, "Z")
>> println v * (m * m) # rotate 30 deg ac/w
>> I found it was simplest just to build-in whatever is needed (this
>> language was used with my 3D graphics app). No imports or libraries
>> are needed, and every user had the same abilities out-of-the-box.
>>
>>
>
> When you have a domain-specific language, and full control of the
> language, then built-ins can be easier. The point of techniques like
> this, whether in Python or C++, is that the language and toolchain only
> needs to support the technique. Then the individual users or library
> vendors can use it for any operations and any types. If someone wants
> to make a type that supports 8 x 8 matrices over complex doubles with a
> binary exponential operator, and write "matrix A = B *pow* C;", then
> they can do that with pretty much identical code as this. Well, they'd
> have to write code for the exponential operator in question, and good
> luck doing that efficiently manner while keeping numeric stability. But
> the wrapping code to support the syntax is straightforward.
>
> Some other languages, like Haskell, make it easier to write your own
> operators and also let you use symbols for them. C++ lets you write
> "rotatematrix(15_deg, "Z")", but not "15°". (You'd have to find a
> Unicode letter that looks like a degree symbol.)
I had the option to use either ° or 'deg':
15 deg
There were a number of such suffixes, which acted as scale factors when
they followed a constant number. Mostly they were used for lengths, such
as "m mm ft ins" (these converted the number to a standard unit, and in
my app that was millimetres).
(I was thinking of bring some of this back, then I looked at the
language Frink which does this stuff on an industrial scale; my efforts
would be utterly feeble.)
Re: variadic min and max, (any some and none, cat and more)
Author: Bonita Montero
Date: Tue, 01 Dec 2026 18:22
Date: Tue, 01 Dec 2026 18:22
28 lines
2191 bytes
2191 bytes
Am 01.12.2026 um 18:48 schrieb bartc:
> I had the option to use either ° or 'deg':
>
> 15 deg
How about that ?
#include <iostream>
#include <complex>
#include <cmath>
using namespace std;
struct degree {};
complex<double> operator *( double angle, degree )
{
return complex<double>( sin( angle ), cos( angle ) );
}
int main()
{
constexpr double Pi4 = 3.1415926535897932384626433832795 / 4.0;
complex<double> dPi4 = Pi4 * degree();
cout << abs( dPi4 ) << endl;
}
Re: variadic min and max, (any some and none, cat and more)
Author: Kaz Kylheku
Date: Tue, 01 Dec 2026 18:47
Date: Tue, 01 Dec 2026 18:47
71 lines
3425 bytes
3425 bytes
On 2026-12-01, Bonita Montero <Bonita.Montero@gmail.com> wrote:
> Am 01.12.2026 um 18:48 schrieb bartc:
>
>> I had the option to use either ° or 'deg':
>>
>> 15 deg
>
> How about that ?
>
> #include <iostream>
> #include <complex>
> #include <cmath>
>
> using namespace std;
>
> struct degree {};
>
> complex<double> operator *( double angle, degree )
complex<double> is too much of a mouthful for a complex type
you will be reaching for a lot.
How it should have been designed is that there should have
been a basic_complex<T> template and complex being a typedef
name for basic_complex<double>
You know, like string being basic_string<char>.
They don't think about ergonomics or consistency at all.
> {
> return complex<double>( sin( angle ), cos( angle ) );
> }
This sin(angle), cos(angle) argument list is the best looking
thing here --- because it's C?
If the C++ people designed it from scratch, it would be some
std::math::sin<double>(angle) type fuckery.
>
> int main()
> {
> constexpr double Pi4 = 3.1415926535897932384626433832795 / 4.0;
This is just stupid; a double only holds around 17 decimal
digits of precision (15 that are guaranteed to be preserved).
Moreover, surely C++ has a pi constant somewhere?
Evidently C++20 has ths:
#include <iostream>
#include <numbers>
// ...
std::numbers::pi;
std::numbers::pi_v<float>;
std::numbers::pi_v<long double>;
It didn't occur to them until the pandemic hit that numeric programmers might
want the language to provide pi.
They hit on the idea of avoiding pi_v<double>, like what I'm talking
about with the complex<T> verbosity above.
--
TXR Programming Language: http://nongnu.org/txr
Cygnal: Cygwin Native Application Library: http://kylheku.com/cygnal
Mastodon: @Kazinator@mstdn.ca
Re: variadic min and max, (any some and none, cat and more)
Author: bartc
Date: Tue, 01 Dec 2026 19:29
Date: Tue, 01 Dec 2026 19:29
46 lines
2755 bytes
2755 bytes
On 01/12/2026 18:22, Bonita Montero wrote:
> Am 01.12.2026 um 18:48 schrieb bartc:
>
>> I had the option to use either ° or 'deg':
>>
>> 15 deg
>
> How about that ?
>
> #include <iostream>
> #include <complex>
> #include <cmath>
>
> using namespace std;
>
> struct degree {};
>
> complex<double> operator *( double angle, degree )
> {
> return complex<double>( sin( angle ), cos( angle ) );
> }
>
> int main()
> {
> constexpr double Pi4 = 3.1415926535897932384626433832795 / 4.0;
> complex<double> dPi4 = Pi4 * degree();
> cout << abs( dPi4 ) << endl;
> }
>
I don't what you're trying to do here or what the purpose of 'complex' is.
Convert radians to degrees? Then this is an easier way to do it:
#define todegrees 57.2968
printf("%f\n", 3.14159 * todegrees); # display ~ 180
But my example went the other way: converting numeric literals
representing degrees, into radians. So it would be done like this:
#define deg 0.01745329...
printf("%f\n", 180 * deg); # display pi
Re: variadic min and max, (any some and none, cat and more)
Author: Bonita Montero
Date: Tue, 01 Dec 2026 19:42
Date: Tue, 01 Dec 2026 19:42
45 lines
3232 bytes
3232 bytes
Am 01.12.2026 um 19:47 schrieb Kaz Kylheku:
> complex<double> is too much of a mouthful for a complex type
> you will be reaching for a lot.
> How it should have been designed is that there should have
> been a basic_complex<T> template and complex being a typedef
> name for basic_complex<double>
But apart from that, you don’t have any other problems, right ?
> If the C++ people designed it from scratch, it would be some
> std::math::sin<double>(angle) type fuckery.
The standard library does not use namespaces quite so excessively,
and there is the `using` keyword.
>> int main()
>> {
>> constexpr double Pi4 = 3.1415926535897932384626433832795 / 4.0;
> This is just stupid; a double only holds around 17 decimal
> digits of precision (15 that are guaranteed to be preserved).
If you sum up the digits backwards, which is the most precise way,
this could make a difference.
> Moreover, surely C++ has a pi constant somewhere?
>
> Evidently C++20 has ths:
>
> #include <iostream>
> #include <numbers>
>
> // ...
> std::numbers::pi;
> std::numbers::pi_v<float>;
> std::numbers::pi_v<long double>;
>
> It didn't occur to them until the pandemic hit that numeric programmers might
> want the language to provide pi.
>
> They hit on the idea of avoiding pi_v<double>, like what I'm talking
> about with the complex<T> verbosity above.
You constantly see problems where there aren't any.
Re: variadic min and max, (any some and none, cat and more)
Author: Bonita Montero
Date: Tue, 01 Dec 2026 19:42
Date: Tue, 01 Dec 2026 19:42
5 lines
1928 bytes
1928 bytes
Am 01.12.2026 um 20:29 schrieb bartc: > I don't what you're trying to do here or what the purpose of 'complex' is. That's the problem - not your code.
Re: variadic min and max, (any some and none, cat and more)
Author: David Brown
Date: Tue, 01 Dec 2026 20:25
Date: Tue, 01 Dec 2026 20:25
54 lines
3995 bytes
3995 bytes
On 01/12/2026 18:48, bartc wrote: > On 01/12/2026 13:53, David Brown wrote: >> On 01/12/2026 13:11, bartc wrote: > >>> Some more: >>> >>> v := (100, 0) >>> m := rotatematrix(15°, "Z") >>> println v * (m * m) # rotate 30 deg ac/w > >>> I found it was simplest just to build-in whatever is needed (this >>> language was used with my 3D graphics app). No imports or libraries >>> are needed, and every user had the same abilities out-of-the-box. >>> >>> >> >> When you have a domain-specific language, and full control of the >> language, then built-ins can be easier. The point of techniques like >> this, whether in Python or C++, is that the language and toolchain >> only needs to support the technique. Then the individual users or >> library vendors can use it for any operations and any types. If >> someone wants to make a type that supports 8 x 8 matrices over complex >> doubles with a binary exponential operator, and write "matrix A = B >> *pow* C;", then they can do that with pretty much identical code as >> this. Well, they'd have to write code for the exponential operator in >> question, and good luck doing that efficiently manner while keeping >> numeric stability. But the wrapping code to support the syntax is >> straightforward. >> >> Some other languages, like Haskell, make it easier to write your own >> operators and also let you use symbols for them. C++ lets you write >> "rotatematrix(15_deg, "Z")", but not "15°". (You'd have to find a >> Unicode letter that looks like a degree symbol.) > > I had the option to use either ° or 'deg': When you are making the language, you make the rules :-) > > 15 deg > > There were a number of such suffixes, which acted as scale factors when > they followed a constant number. Mostly they were used for lengths, such > as "m mm ft ins" (these converted the number to a standard unit, and in > my app that was millimetres). > Was it just a scaling factor, or did you distinguish types? In C++, when you do this sort of thing (called "user-defined literals") you generally attach a specific type to it. Thus if you have "auto x = 10_m;", "auto y = 5_s;", trying to add x and y (adding a distance to a time) would be a compile-time error - but you could divide them to get a speed.
Re: variadic min and max, (any some and none, cat and more)
Author: David Brown
Date: Tue, 01 Dec 2026 20:47
Date: Tue, 01 Dec 2026 20:47
55 lines
3243 bytes
3243 bytes
On 01/12/2026 20:29, bartc wrote:
> On 01/12/2026 18:22, Bonita Montero wrote:
>> Am 01.12.2026 um 18:48 schrieb bartc:
>>
>>> I had the option to use either ° or 'deg':
>>>
>>> 15 deg
>>
>> How about that ?
>>
>> #include <iostream>
>> #include <complex>
>> #include <cmath>
>>
>> using namespace std;
>>
>> struct degree {};
>>
>> complex<double> operator *( double angle, degree )
>> {
>> return complex<double>( sin( angle ), cos( angle ) );
>> }
>>
>> int main()
>> {
>> constexpr double Pi4 = 3.1415926535897932384626433832795 / 4.0;
>> complex<double> dPi4 = Pi4 * degree();
>> cout << abs( dPi4 ) << endl;
>> }
>>
>
> I don't what you're trying to do here or what the purpose of 'complex' is.
>
Bonita is representing a 2D position as a complex number - thus a
rotation about the origin by an angle x is the same as multiplying by
the complex number e ^ i.x, or cos(x) + i.sin(x). It's a common and
useful representation, but it does not fit with either the original 3D
vectors, or your "rotatematrix" function.
> Convert radians to degrees? Then this is an easier way to do it:
>
> #define todegrees 57.2968
>
> printf("%f\n", 3.14159 * todegrees); # display ~ 180
>
> But my example went the other way: converting numeric literals
> representing degrees, into radians. So it would be done like this:
>
> #define deg 0.01745329...
>
> printf("%f\n", 180 * deg); # display pi
>
>
Re: variadic min and max, (any some and none, cat and more)
Author: bartc
Date: Tue, 01 Dec 2026 21:09
Date: Tue, 01 Dec 2026 21:09
72 lines
4828 bytes
4828 bytes
On 01/12/2026 20:25, David Brown wrote: > On 01/12/2026 18:48, bartc wrote: >> On 01/12/2026 13:53, David Brown wrote: >>> On 01/12/2026 13:11, bartc wrote: >> >>>> Some more: >>>> >>>> v := (100, 0) >>>> m := rotatematrix(15°, "Z") >>>> println v * (m * m) # rotate 30 deg ac/w >> >>>> I found it was simplest just to build-in whatever is needed (this >>>> language was used with my 3D graphics app). No imports or libraries >>>> are needed, and every user had the same abilities out-of-the-box. >>>> >>>> >>> >>> When you have a domain-specific language, and full control of the >>> language, then built-ins can be easier. The point of techniques like >>> this, whether in Python or C++, is that the language and toolchain >>> only needs to support the technique. Then the individual users or >>> library vendors can use it for any operations and any types. If >>> someone wants to make a type that supports 8 x 8 matrices over >>> complex doubles with a binary exponential operator, and write "matrix >>> A = B *pow* C;", then they can do that with pretty much identical >>> code as this. Well, they'd have to write code for the exponential >>> operator in question, and good luck doing that efficiently manner >>> while keeping numeric stability. But the wrapping code to support >>> the syntax is straightforward. >>> >>> Some other languages, like Haskell, make it easier to write your own >>> operators and also let you use symbols for them. C++ lets you write >>> "rotatematrix(15_deg, "Z")", but not "15°". (You'd have to find a >>> Unicode letter that looks like a degree symbol.) >> >> I had the option to use either ° or 'deg': > > When you are making the language, you make the rules :-) > >> >> 15 deg >> >> There were a number of such suffixes, which acted as scale factors >> when they followed a constant number. Mostly they were used for >> lengths, such as "m mm ft ins" (these converted the number to a >> standard unit, and in my app that was millimetres). >> > > Was it just a scaling factor, or did you distinguish types? In C++, > when you do this sort of thing (called "user-defined literals") you > generally attach a specific type to it. Thus if you have "auto x = > 10_m;", "auto y = 5_s;", trying to add x and y (adding a distance to a > time) would be a compile-time error - but you could divide them to get a > speed. > It's just a scale factor. The result is a generic FP type. I have looked into properly implementing units, where multiplying tgwo length types for example gives you an area type, and where area + length is not allowed, but it very quickly gets out of hand and turns into a can of works. In any case it requires a much stricter, and hierarchical, type system, such as you might find in Ada, and may be possible in C++. I mentioned Frink (https://frinklang.org/) which supports thousands of physical units. That is so comprehensive that I decided it would be pointless to emulate a tiny fraction of it within my own PL. That's fine; my Casio works perfectly will with unitless numbers. So can a PL!
Re: variadic min and max, (any some and none, cat and more)
Author: fir
Date: Tue, 01 Dec 2026 22:27
Date: Tue, 01 Dec 2026 22:27
87 lines
5572 bytes
5572 bytes
bartc pisze: > On 01/12/2026 20:25, David Brown wrote: >> On 01/12/2026 18:48, bartc wrote: >>> On 01/12/2026 13:53, David Brown wrote: >>>> On 01/12/2026 13:11, bartc wrote: >>> >>>>> Some more: >>>>> >>>>> v := (100, 0) >>>>> m := rotatematrix(15°, "Z") >>>>> println v * (m * m) # rotate 30 deg ac/w >>> >>>>> I found it was simplest just to build-in whatever is needed (this >>>>> language was used with my 3D graphics app). No imports or libraries >>>>> are needed, and every user had the same abilities out-of-the-box. >>>>> >>>>> >>>> >>>> When you have a domain-specific language, and full control of the >>>> language, then built-ins can be easier. The point of techniques >>>> like this, whether in Python or C++, is that the language and >>>> toolchain only needs to support the technique. Then the individual >>>> users or library vendors can use it for any operations and any >>>> types. If someone wants to make a type that supports 8 x 8 matrices >>>> over complex doubles with a binary exponential operator, and write >>>> "matrix A = B *pow* C;", then they can do that with pretty much >>>> identical code as this. Well, they'd have to write code for the >>>> exponential operator in question, and good luck doing that >>>> efficiently manner while keeping numeric stability. But the >>>> wrapping code to support the syntax is straightforward. >>>> >>>> Some other languages, like Haskell, make it easier to write your own >>>> operators and also let you use symbols for them. C++ lets you write >>>> "rotatematrix(15_deg, "Z")", but not "15°". (You'd have to find a >>>> Unicode letter that looks like a degree symbol.) >>> >>> I had the option to use either ° or 'deg': >> >> When you are making the language, you make the rules :-) >> >>> >>> 15 deg >>> >>> There were a number of such suffixes, which acted as scale factors >>> when they followed a constant number. Mostly they were used for >>> lengths, such as "m mm ft ins" (these converted the number to a >>> standard unit, and in my app that was millimetres). >>> >> >> Was it just a scaling factor, or did you distinguish types? In C++, >> when you do this sort of thing (called "user-defined literals") you >> generally attach a specific type to it. Thus if you have "auto x = >> 10_m;", "auto y = 5_s;", trying to add x and y (adding a distance to a >> time) would be a compile-time error - but you could divide them to get >> a speed. >> > > It's just a scale factor. The result is a generic FP type. > > I have looked into properly implementing units, where multiplying tgwo > length types for example gives you an area type, and where area + length > is not allowed, but it very quickly gets out of hand and turns into a > can of works. > > In any case it requires a much stricter, and hierarchical, type system, > such as you might find in Ada, and may be possible in C++. > > I mentioned Frink (https://frinklang.org/) which supports thousands of > physical units. That is so comprehensive that I decided it would be > pointless to emulate a tiny fraction of it within my own PL. > > That's fine; my Casio works perfectly will with unitless numbers. So can > a PL! as tu units i just defined 2 constants in my rasterizer const float G=0.0545f; // ziemskie G 9.81 m/s² const float O=0.0002777778f; // 1 obrót/s² one is linear acceleration unit and one angular acceleration unit my ship having acc = 2*G; yaw_acc = 1*O; seem reasoneble (and opponent ships having also some of that) if im wrong some could correct me, as im not sure if im fully right (those values come from he fat tkah 1 linear is 5 cm here (or 5 cm here is 1 there) and 1 second is 60 frames, 1.0 is full turn
Re: variadic min and max, (any some and none, cat and more)
Author: fir
Date: Tue, 01 Dec 2026 22:32
Date: Tue, 01 Dec 2026 22:32
92 lines
5790 bytes
5790 bytes
fir pisze: > bartc pisze: >> On 01/12/2026 20:25, David Brown wrote: >>> On 01/12/2026 18:48, bartc wrote: >>>> On 01/12/2026 13:53, David Brown wrote: >>>>> On 01/12/2026 13:11, bartc wrote: >>>> >>>>>> Some more: >>>>>> >>>>>> v := (100, 0) >>>>>> m := rotatematrix(15°, "Z") >>>>>> println v * (m * m) # rotate 30 deg ac/w >>>> >>>>>> I found it was simplest just to build-in whatever is needed (this >>>>>> language was used with my 3D graphics app). No imports or >>>>>> libraries are needed, and every user had the same abilities >>>>>> out-of-the-box. >>>>>> >>>>>> >>>>> >>>>> When you have a domain-specific language, and full control of the >>>>> language, then built-ins can be easier. The point of techniques >>>>> like this, whether in Python or C++, is that the language and >>>>> toolchain only needs to support the technique. Then the individual >>>>> users or library vendors can use it for any operations and any >>>>> types. If someone wants to make a type that supports 8 x 8 >>>>> matrices over complex doubles with a binary exponential operator, >>>>> and write "matrix A = B *pow* C;", then they can do that with >>>>> pretty much identical code as this. Well, they'd have to write >>>>> code for the exponential operator in question, and good luck doing >>>>> that efficiently manner while keeping numeric stability. But the >>>>> wrapping code to support the syntax is straightforward. >>>>> >>>>> Some other languages, like Haskell, make it easier to write your >>>>> own operators and also let you use symbols for them. C++ lets you >>>>> write "rotatematrix(15_deg, "Z")", but not "15°". (You'd have to >>>>> find a Unicode letter that looks like a degree symbol.) >>>> >>>> I had the option to use either ° or 'deg': >>> >>> When you are making the language, you make the rules :-) >>> >>>> >>>> 15 deg >>>> >>>> There were a number of such suffixes, which acted as scale factors >>>> when they followed a constant number. Mostly they were used for >>>> lengths, such as "m mm ft ins" (these converted the number to a >>>> standard unit, and in my app that was millimetres). >>>> >>> >>> Was it just a scaling factor, or did you distinguish types? In C++, >>> when you do this sort of thing (called "user-defined literals") you >>> generally attach a specific type to it. Thus if you have "auto x = >>> 10_m;", "auto y = 5_s;", trying to add x and y (adding a distance to >>> a time) would be a compile-time error - but you could divide them to >>> get a speed. >>> >> >> It's just a scale factor. The result is a generic FP type. >> >> I have looked into properly implementing units, where multiplying tgwo >> length types for example gives you an area type, and where area + >> length is not allowed, but it very quickly gets out of hand and turns >> into a can of works. >> >> In any case it requires a much stricter, and hierarchical, type >> system, such as you might find in Ada, and may be possible in C++. >> >> I mentioned Frink (https://frinklang.org/) which supports thousands of >> physical units. That is so comprehensive that I decided it would be >> pointless to emulate a tiny fraction of it within my own PL. >> >> That's fine; my Casio works perfectly will with unitless numbers. So >> can a PL! > as tu units i just defined 2 constants in my rasterizer > > const float G=0.0545f; // ziemskie G 9.81 m/s² > const float O=0.0002777778f; // 1 obrót/s² > > one is linear acceleration unit and one angular acceleration unit > > my ship having acc = 2*G; yaw_acc = 1*O; seem reasoneble > (and opponent ships having also some of that) > > if im wrong some could correct me, as im not sure if im fully right > > (those values come from he fat tkah 1 linear is 5 cm here (or 5 cm here > is 1 there) and 1 second is 60 frames, 1.0 is full turn some may check it at https://lord-fir.itch.io/lean-fire-shots
Re: variadic min and max, (any some and none, cat and more)
Author: Lawrence D’Oliveiro
Date: Wed, 02 Dec 2026 02:04
Date: Wed, 02 Dec 2026 02:04
18 lines
2222 bytes
2222 bytes
On Tue, 1 Dec 2026 16:33:24 +0100, Bonita Montero wrote:
> Am 01.12.2026 um 14:53 schrieb David Brown:
>
>> Some other languages, like Haskell, make it easier to write your
>> own operators and also let you use symbols for them. C++ lets you
>> write "rotatematrix(15_deg, "Z")", but not "15°". (You'd have to
>> find a Unicode letter that looks like a degree symbol.)
>>
> This is sth. similar in C++:
>
> complex<double> operator ""_degree( long double angle )
> {
> return complex<double>( sin( angle ), cos( angle ) );
> }
I don’t see any such C++ feature
<https://cppreference.com/cpp/language/operators>.
Re: variadic min and max, (any some and none, cat and more)
Author: Keith Thompson
Date: Wed, 02 Dec 2026 02:19
Date: Wed, 02 Dec 2026 02:19
26 lines
2593 bytes
2593 bytes
Lawrence D’Oliveiro <ldo@nz.invalid> writes:
> On Tue, 1 Dec 2026 16:33:24 +0100, Bonita Montero wrote:
>> Am 01.12.2026 um 14:53 schrieb David Brown:
>>> Some other languages, like Haskell, make it easier to write your
>>> own operators and also let you use symbols for them. C++ lets you
>>> write "rotatematrix(15_deg, "Z")", but not "15°". (You'd have to
>>> find a Unicode letter that looks like a degree symbol.)
>>>
>> This is sth. similar in C++:
>>
>> complex<double> operator ""_degree( long double angle )
>> {
>> return complex<double>( sin( angle ), cos( angle ) );
>> }
>
> I don’t see any such C++ feature
> <https://cppreference.com/cpp/language/operators>.
I do.
If you want to know more about this feature, consult a C++
reference or tutorial or ask in comp.lang.c++.
--
Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com
void Void(void) { Void(); } /* The recursive call of the void */
Page 2 of 3 • 103 total messages
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads