Get the latest tech news

Rust Devs Think We're Hopeless; Let's Prove Them Wrong (With C++ Memory Leaks)


Rust Devs Think We’re Hopeless; Let’s Prove Them Wrong (with C++ Memory Leaks)! When Rust developers think of us C++ folks, they picture a cursed bloodline — generational trauma passed down from malloc to free. To them, every line of C++ we write is like playing Russian Roulette — except all six chambers are loaded with undefined behavior. They look at us like we’re hopeless. Like we’re one dangling pointer away from therapy. But you know what? We don’t need a compiler nanny. No borrow checker. No lifetimes. No ownership models. No black magic. Not even Valgrind is required. Just raw pointers, raw determination, and a bit of questionable sanity. So in this video, I’m going to show you how to hunt down memory leaks like you were born with a pointer in one hand and a debugger in the other. If that sounds unreasonably dangerous — and incredibly fun — smash that subscribe button, and let’s dive into the deep end of the heap.

When Rust developers think of us C++ folks, they picture a cursed bloodline — generational trauma passed down from malloc to free. If that sounds unreasonably dangerous — and incredibly fun — smash that subscribe button, and let’s dive into the deep end of the heap. tl;dr;_CrtSetDbgFlag(...) enables runtime heap tracking and leak reports;_CrtSetBreakAlloc(N) lets you break on a specific allocation number.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of c++ memory leaks

c++ memory leaks

Photo of rust devs

rust devs