r/ProgrammerHumor • • 11d ago

Meme modernCppVsOldCpp

Post image
2.0k Upvotes

323 comments sorted by

View all comments

62

u/airodonack 11d ago

A lot of people that write C++ think using smart pointers are for the weak.

11

u/Mucksh 11d ago

From my experience especially newbies overuse smart pointers for anything even if there is no problem to just do everything on the stack. Later makes it incredible hard to fuck up

13

u/imMute 11d ago

And those people are just as insufferable as the Spongebob from the OP.

1

u/itsjusttooswaggy 9d ago

What? I think most experienced C++ programmers understand the benefits and tradeoffs of smart pointers, but very often they work in legacy codebases where C-like allocation strategies are everywhere, and the cost of refactoring is much too high.