83
submitted 1 week ago* (last edited 1 week ago) by sanitation@lemmy.radio to c/programming@programming.dev

aka "bros: in order to be rich, just don't be poor."

you are viewing a single comment's thread
view the rest of the comments
[-] JakenVeina@midwest.social 47 points 1 week ago

To be clear, he's not saying "just code better", as the title implies. It's a really poor choice of title.

you are going to mess up somewhere and get leaks, stray pointers, etc. This is true independently of how conscientious you are with your allocations:

He goes on to say, effectively, "Don't use new/delete/malloc/free if you can help it. Use smarter mechanisms."

[-] sik0fewl@lemmy.ca 4 points 1 week ago

Ya, I don’t think he actually said that since it’s not mentioned in the referenced article. What’s actually meant is “by writing code that doesn’t have any memory management”.

[-] avocado@programming.dev 3 points 1 week ago* (last edited 1 week ago)

C++'s so called smarter mechanisms are ugly af. I would rather my RAM crash and burn than use its standard library.

[-] chunes@lemmy.world 4 points 1 week ago

yeah. I'd rather use C and statically allocate everything up front, even if that's not a great fit

[-] sobchak@programming.dev 2 points 6 days ago

When I did embedded programming that's what I did. Nothing was dynamically allocated. It also allowed me to write a debugger that would watch how variables changed by just directly reading from memory, chart them, and and stuff like that.

this post was submitted on 09 May 2026
83 points (100.0% liked)

Programming

26966 readers
688 users here now

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you're posting long videos try to add in some form of tldr for those who don't want to watch videos

Wormhole

Follow the wormhole through a path of communities !webdev@programming.dev



founded 2 years ago
MODERATORS