News for hackers. Stuff that matters.
Re:Rust: Dropping heavy things in another thread can make yo... by jfkebwjsbx on Sunday May 31, 2020 @01:34AM (#23367443)
> That very thing can easily happen in the real world.

Only if badly designed. That is why it is contrived!

> While that may seem contrived, consider a vector of 1 million strings, something that's not too uncommon

A program dealing with a million elements of any kind should not be performing naive allocations to begin with.

> we do deallocation trickery in the real world

Skipping deallocations is an optimization, not a design pattern.

In other words, the code needs to keep the ability to perform the deallocation for debugging, testing, usage as a library, etc.

There are no comments on this comment yet.