3 ms·
I don't think Rust even allows you to free your own memory without calling into libc, but then again I suppose you could say the same thing about C.
by Sean1708 10y ago
I don't think Rust even allows you to free your own memory without calling into libc, but then again I suppose you could say the same thing about C.
- steveklabnik 10y agoNot on stable. On unstable you'd have a few options, similar to the ones you'd have for writing libc in the first place.
- moosingin3space 10y agoCan't you use mem::drop to (effectively) deallocate memory before it goes out of scope? (I know this isn't quite the same thing as liballoc on nightly)
- steveklabnik 10y agoThat's true. Even though my parent said "free", I just assumed both sides of the equation :)