r/cpp • u/Mango-D • Jan 08 '25
children discuss constexpr in C++
https://youtu.be/pSptWKdOHYc99
Jan 08 '25
terrifying child abuse
22
41
4
u/exus1pl Jan 08 '25
I mean, they could teach them just C.
16
u/UsedOnlyTwice Jan 09 '25
You don't teach small children C. You just give them a few pointers and make sure they wash their hands often.
1
28
u/antiquark2 #define private public Jan 09 '25
This is obviously propaganda from the rust community.
8
Jan 09 '25
Fake, I don't see any desperation, lack of sleep or fidgeting because you want to get into the habit of stress smoking.
4
u/dexter2011412 Jan 09 '25
lmao haha
Me: tries to constexpr compile with a string ...
compiler: nope it's a function argument can't determine AAAAA
Me: here it's a template parameter now
compiler: YAY!
Me: hmmmm ... constexpr function arguments pls?
Also I didn't get the PHP joke. Could someone explain it to me?
4
u/foonathan Jan 09 '25
Also I didn't get the PHP joke. Could someone explain it to me?
When a paper was discussedin committee about allowing arbitrary compile-time evaluation, someone brought up PHP as a counter argument. It was as much of a non sequitur as in the video.
2
u/iamjkdn Jan 09 '25
Explain like I am five?
7
u/Spare-Builder-355 Jan 09 '25
Children just literally explained it in the video - do not constexpr all things, it makes cross-compilation impossible and allows code execution in your compiler. Also php.
2
1
3
61
u/GroutLloyd Jan 08 '25
If they spoke slower, more awkward, I could have believed they are truly geeked on C++ though....
As now, it's obviously for the LOL.