this post was submitted on 29 Aug 2024
8 points (100.0% liked)

Programmer Humor

32000 readers
1744 users here now

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

founded 5 years ago
MODERATORS
 
top 9 comments
sorted by: hot top controversial new old
[–] [email protected] 1 points 2 weeks ago

I love C++ I love C++ I love C++ I love C++

>does big something with C++

I hate C++ I hate C++ I hate C++ I hate C++

[–] [email protected] 1 points 2 weeks ago (1 children)

C++ is fiiiiine. Just use the modern variant of the language, don't bother with hand-optimizing your memory allocators, and generally avoid anything involving pointer arithmetics. So, basically, use it like you would use Python.

[–] [email protected] 2 points 2 weeks ago (1 children)

So, basically, use it like you would use Python.

That's a great way to get performance as shitty as python's.

[–] [email protected] 0 points 2 weeks ago (1 children)

C++ can do a lot of things but one thing it can't do is perform as poorly as python.

[–] [email protected] 0 points 2 weeks ago (1 children)
[–] [email protected] 0 points 2 weeks ago (1 children)

What's wrong with embedded C? Would you rather write assembly?

[–] [email protected] 0 points 2 weeks ago* (last edited 2 weeks ago) (1 children)

Hey assembly is good in the sense you are only dealing with one language but in embedded C you get bad parts of both C and assembly. You have to follow weird C99 or even C89 syntax and on top of that for each micro controllers you have to sift through several hundred pages of data sheet. Each one needing separate registers to be setup in a particular way for every single operation and so much more stupid ass shit.

[–] [email protected] 1 points 2 weeks ago* (last edited 2 weeks ago)

All of the quirks you said are true, yet they still established the "okay" ecosystem of hobby-grade microcontrollers like Arduino, IoT devices, and other small scale robotics systems. None of them would have happened without the "okay" abstraction C/C++ provides as opposed to assembler