3 ms·
Rust allows you to layer on “just the heap please” and yes, many projects do exactly that. The point is that it is clearly delineated: no_std has no system depe
by steveklabnik 5y ago
Rust allows you to layer on “just the heap please” and yes, many projects do exactly that. The point is that it is clearly delineated: no_std has no system dependencies, and then you can layer things like alloc on top of that, up to and maybe finally including full standard library support. Rust allows projects to explicitly signal what stuff they need, which helps make the ecosystem interoperable, which is the point made in the talk.
Incidentally, “every” OS does not have a heap. Many do, possibly even “most,” but that’s not required. It is extremely nice to be able to know what needs a heap and what does not.
- ncmncm 5y agoI made no claim that every OS has a heap. Every OS does manage memory, and use memory. It is not just nice, but essential, to know what needs a heap. And, every embedded coder does know. Or quickly learns.
- deleted 5y ago[deleted]
- tialaramex 5y ago> I made no claim that every OS has a heap. > Billions of embedded devices reserve and manage heap memory without difficulty. Indeed, every OS kernel is running in just such an embedded environment. You claim every OS kernel is "running in just such an embedded environment" and you describe that environment by saying it does "reserve and manage heap memory without difficulty". (My emphasis). Would you like to explain how this is different from the claim you now say you didn't make?
- ncmncm 5y agoI invite you to read more carefully, and think for a moment. I am confident you will puzzle it out. Maybe ask Steve, he figured it out.
- steveklabnik 5y agoI didn’t figure it out, it was just clear this conversation wasn’t going anywhere so I decided to drop it.
- ncmncm 5y agoSmart. But I'm confident you would have.