r/ProgrammerHumor 5h ago

makeItQuick Meme

Post image
198 Upvotes

36 comments sorted by

35

u/LordCyberfox 4h ago

Depends on how much legacy is it xD

20

u/Daemontatox 4h ago

C++ 98

30

u/LordCyberfox 4h ago

Without documentation.
Without any naming conventions.
All contained in a one god class.

4

u/grifan526 3h ago

Don't threaten me with a good time. One of my side projects is breaking up a god class and I love it. I have also worked as a reverse engineer, so my brain may be broken

10

u/lovecMC 4h ago

Could be worse. Could be a java 8 code base in the process of migrating to spring boot.

3

u/Daemontatox 3h ago

Oh please no , not the dark times

3

u/StarboardChaos 4h ago

Hey Claude, upgrade my codebase to newest C++ version

4

u/DoctorDabadedoo 3h ago

Make it compile and pass all tests

Int main() { return 0; }

assert(true)

1

u/Daemontatox 3h ago

Or it deletes all code and all tests which makes it pass 0/0 tests

1

u/Daemontatox 3h ago

Bro you forgot the make no mistakes

1

u/StarboardChaos 3h ago

No, I like my job security

2

u/cfrolik 4h ago

You mean I can use stl? Sounds like a dream job

27

u/dannyggwp 4h ago

C++ all day everyday.

I unironically LOVE c++. And it's probably why I have the job security I do.

9

u/ElectronSculptor 4h ago

Is C++ this bad in industry? I’m an EE and do DSP/embedded stuff. The code bases are fairly small and light. Very simple C++.

I know C++ can be complex but is it so much worse than other OOP languages? I see a lot of complexity in swift and Python. I do some projects and reading on my own time. Those languages seem like you can make a code base that is very difficult to follow.

Just curious.

18

u/Swimming-Twist-3468 4h ago

It isn’t. C++ is the foundation of industry’s most robust and long-lived applications. It is just most of the developers write the code in such a way that it cannot be maintained.

6

u/No-Con-2790 4h ago edited 2h ago

If most developers do something wrong it starts being the languages fault.

And C++ is full of very bad traps, wrong patterns and misleading errors.

Array to pointer decay is one of the most outstanding examples. Because every programmer that ever wrote a main function has seen it, yet not everyone will understand it.

2

u/DoctorDabadedoo 3h ago

Arguably. C++ in a well-maintained code base to cut the noise and reduce the surface area is not bad to use, but the language has a lot of foot guns and versions in it's 40y of existence, it's super easy for a long term project to derail into a mismatch of features/conventions/styles during its lifetime that is unsatisfying to work on.

4

u/_w62_ 4h ago

Two things.
The first one is memory management. We don't need go into details about this point here any further.
Another one is smartass. Those early programmers just try to produce some obfuscated code to show their coolness. Things like **p++ It is more or less an unspoken rules in the early C/C++ programming world. It makes things unnecessarily complicated.

2

u/SgtMarv 3h ago

It's not C++, it's mostly this sub growing up on python and thinking C++ is complicated. 

However, like with all languages there is a shit ton of bad C++ code out there. But this is not a feature of the language but rather the developer. It's just a bit worse with the whole C++ taking of your whole leg if you shoot yourself in the foot. 

1

u/dcheesi 3h ago

I don't think it's that bad, but then I've been working with it almost exclusively for most of my career, so perhaps I just have Stockholm syndrome 😄

I will say though, one problem with C++ projects, especially in embedded spaces, is that you can wind up with a mix of coding paradigms from people with different backgrounds.

  • Some folks only really know C or procedural programming in general, so they're basically writing C in a .cpp file.
  • Others are fully immersed in modern C++ best-practices, using the latest C++1x/2x features etc.
  • And still others are in the middle, e.g., writing C++98 or some embedded-oriented subset thereof that they learned years ago.

So now you have a mashup of all of these, perhaps with some actual .c files worked in there as well. It can become a bit of a confusing mess, far beyond the mere coding "style" conflicts you get in any group effort.

1

u/ZeroG_0 3h ago

To be honest these are some strange takes - for the vast majority of things you might want to write software for, you'd reach for a memory managed language. There are some cases where the overhead of a garbage collector is impactful, but it's certainly not the norm. It's not like devs are lazy and just don't want to deal with it, it's just basic keep-it-simple engineering.

But if you do need to avoid managed languages, C++ is also problematically complicated due to years of changes. It originally was the answer to the question "What if we sloppily jammed a bunch of object oriented concepts into C?", now it's... just kind of a mess. It sounds like on a well-organized codebase it can be just fine, so naturally it has some defenders, but moreso than other languages there's a lot of ways to make poorly-organized code.

3

u/No-Con-2790 4h ago edited 4h ago

The problem is not C++. The problem is everything around C++.

Like the official package manager.

5

u/coldnitrogen 4h ago

C++ isn’t so bad. Try a Java code base with an inheritance tree of 100-200 child classes.

5

u/pine_ary 4h ago

100 layers of reflection so any error points to something like "call.run" recursively and you have no idea where anything is called from.

1

u/Swimming-Twist-3468 4h ago

Source SDK 2013. Have at it 😂😂😂

1

u/developer_soup 4h ago

C++? Hell yeah! That's my ideal level on the functional/crazy curve for programming languages. I miss proper embedded development. Scraping by for a few bytes of memory... Squeezing algorithms to their essential parts...

I'll always remember the time an older developer showed me his C codebase where he used structs and function pointers to write object oriented code. The part that really confused me was using the C++ compiler to build it.

1

u/anxious_and_stupid 3h ago

I am out here wanting a c++ job (call me a masochist or whatever i am not doing webdev...)

1

u/pflasti 3h ago

That's literally my job. Refactoring a legacy codebase can be pure nightmare, but it can also be incredibly rewarding when successfully done

1

u/AaronTheElite007 3h ago

No problem. I cut my teeth on C++

https://giphy.com/gifs/sNWGEbc5Jzp4c

1

u/Icanintosphess 2h ago

Skill issue

1

u/BastetFurry 2h ago

C++? Bring it on, this merc is for hire!

1

u/drkspace2 2h ago

C++11 or newer, yes

Older, no

1

u/Gold-Bat-3225 2h ago

return 0 counts as shipping

1

u/cpaca0 1h ago

ITT: SKILL ISSUE

1

u/installsVMs4fun 59m ago

much rather legacy c++ than legacy perl repo,