|
It's the brits fault, they colonized even C++.
GCS d--(d+) s-/++ a C++++ U+++ P- L+@ E-- W++ N+ o+ K- w+++ O? M-- V? PS+ PE- Y+ PGP t+ 5? X R+++ tv-- b+(+++) DI+++ D++ G e++ h--- r+++ y+++* Weapons extension: ma- k++ F+2 X
|
|
|
|
|
A colon is the hat that most Q&A questioners wear.
If you can't laugh at yourself - ask me and I will do it for you.
|
|
|
|
|
static member access, constructor initialization list. Base class list, namespace access, ternary operator, case signifier terminator.
I feel like there are more but I'm sleepy.
edit: other commenters pointed out labels and bitfields
Don't forget to escape strings and chars!
Real programmers use butterflies
|
|
|
|
|
also bitfield definitions
|
|
|
|
|
Thanks. I knew i was forgetting something!
Real programmers use butterflies
|
|
|
|
|
goto the head of the class!
If you can't laugh at yourself - ask me and I will do it for you.
|
|
|
|
|
i forgot labels.
So now that's two things i forgot
Real programmers use butterflies
|
|
|
|
|
global scope operator, as in ::foo
#SupportHeForShe
Government can give you nothing but what it takes from somebody else. A government big enough to give you everything you want is big enough to take everything you've got, including your freedom.-Ezra Taft Benson
You must accept 1 of 2 basic premises: Either we are alone in the universe or we are not alone. Either way, the implications are staggering!-Wernher von Braun
|
|
|
|
|
I presumed that was implied when i mentioned the namespace scope resolution operator (it's the same operator)
Real programmers use butterflies
|
|
|
|
|
In a ternary oparator
sResult=(x<=0)?"0 or negative":"positive";
|
|
|
|
|
i already mentioned that.
Real programmers use butterflies
|
|
|
|
|
|
is that a C++20 thing?
Real programmers use butterflies
|
|
|
|
|
|
huh. I've never actually used that..
Real programmers use butterflies
|
|
|
|
|
Some of those are double colons. Are we counting them as well?
|
|
|
|
|
i did, because of the way the original question was worded.
Real programmers use butterflies
|
|
|
|
|
To keep my gastroenterologist in BMW's?
Oh wait, wrong colon; my bad.
Software Zen: delete this;
|
|
|
|
|
I'm surprised no one got this:
Between two points, it takes two seconds to be single. (9)
Between two points ONE LINE
it takes two seconds SS to be single. (9)
ONELINESS[^]
Apropos of the current human condition, I think...
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
I did think of line being part of the answer. But I would have lost the house betting that oneliness isn't a word.
|
|
|
|
|
I was nowhere with this - points mean compass points to me - I had momo for two seconds - you are up again tomorrow
"I didn't mention the bats - he'd see them soon enough" - Hunter S Thompson - RIP
|
|
|
|
|
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
I hardly know English, but look up every word comes up as solution in CCC...
In this case Webster knows only ONLINESS (despite the cite on Free Dictionary), and Wiktionary defines it as obsolete - No longer in use, and (of a term) no longer likely to be understood...
"The only place where Success comes before Work is in the dictionary." Vidal Sassoon, 1928 - 2012
|
|
|
|
|
For those of you that don't know,
C++ allows you to use templates to trade bigger code size for more speed or more flexibility.
C++ also allows you to use templates to reduce code size while maintaining flexibility.
It all depends on how you use it but it makes for some hairy design decisions.
I'll give you the scenario that gave rise to this missive:
I have a weird video frame buffer format I want to be able to back with an in memory bitmap.
I currently do that. However, the bitmap is not mapped in the same way as the frame buffer so on copy it has to massage the data into the framebuffer format.
It got me thinking, what if I could, in addition to specifying the in memory format of the bitmap in terms of its pixels, what if I could also tell it how to lay those pixels out in memory, rather than forcing it to go left to right, top to bottom?
It complicates the situation where you're blting/copying from a bitmap to one with a different in memory mapping, requiring additional code to be generated to handle that case.
...as well as the case where you're going between two bitmaps with the same mapping format at which point each mapping type needs an optimized blt/copy to go from bitmaps of the same type, for efficiency.
This creates a situation where you're potentially generating more code if you create or use a new bitmap mapping format because at some point you'll probably need to do transfers between and regular bitmaps, causing that generic code above to be generated, but also between bitmaps of the same mapping types causing the optimized mapping code for each to be put in the binary as well.
The advantage is you can create new framebuffers for weird video hardware, and treat them like normal bitmaps, at the expense of a larger binary, and of course some mapping overhead. But you can just do drawing operations over your framebuffer, and rather than adjusting the data post-draw during the copy to the video device, it makes it so that the buffer is created in the video hardware's format *during* the draw operations.
The question becomes, is it all worth it?
Does the code bloat overshadow the flexibility?
I can't tell until I implement it. I just won't know without trying it. There are too many factors to determine how it will play in the real world without building it out and throwing some scenarios at it.
Here's the thing.
With most languages, I wouldn't be stuck on design decisions like this simply for the fact that they do not exist. Most languages don't allow you to make decisions like these. You're stuck without the option in the first place, so you just have to dance with who brought ya.
And then I think, well, most languages are just fine without all these capabilities, so maybe I'm just spinning my wheels, or at least traversing rabbit holes that wouldn't even exist in say, C#
But then I also remember that C# code will not run on an ESP32 or similar, for good reason. I don't have RAM and cycles to waste.
Admittedly, most of the features I like using in C++ I don't strictly need. I use them to make my code more flexible, or tighter, or otherwise make it work exactly the way I want, but sometimes I think I'm just borrowing trouble - being overly perfectionist about it in ways that other languages don't even allow me to do.
Is it too much freedom and flexibility for my own good? And the fact that I have to keep asking myself that both sort of reinforces the idea that maybe it isn't so good, and also kind of freaks me out in terms of my political sensibilities given how ... libertine I tend to be. Why would I ask myself if this much freedom is too much? And does this say anything larger about where my head is at?
And then C++ starts giving me an existential crisis.
Real programmers use butterflies
|
|
|
|
|
Welcome to a multiparadigm language.
"In testa che avete, Signor di Ceprano?"
-- Rigoletto
|
|
|
|