Conversation

Jarkko Sakkinen

Edited 1 year ago

heapless is by far my favorite #Rust #crate as it fixes things that annoy me the most in the current standard library. I.e. it enforces explicit checks. #rustlang

0
0
4
@sgued Optimal would be if Rust would require explicit allocations and checks for OOM conditions. The way heap works in Rust's stdlib is not how I would like it to work and heapless is best suboptimal solution for that to this date...

Rust's borrow checker is essentially solution for only one vector of memory conditions, i.e. it does not deal with over-consumption of memory.
0
0
0
@sgued Kernel is a resource manager if you strip down the gist of it.

Anything else with some sort of resource manager benefits from more stringent memory management.

Most of the stuff that make money-wise sense to do in Rust ends up being some sort of resource manager in any kind of commercial setting.

For stuff that is not resource manager it is cheaper to use something like Python or (ugh) JavaScript. For non-trivial orchestration something like Go is factors more productive than Rust. Where Rust makes generally sense is where you want to pay more from R&D.

E.g. if you strip down the gist of something like Unreal Engine, it is a resource manager.

Not really much to do with kernel in that sense. It is just that Rust does not support all features where it is profitable for business to invest in Rust.
1
0
0
@sgued When I started programing, I used Turbo Pascal and Turbo Assembler a lot. Turbo Pascal was basically like Rust, and Rust is like modern take on Niklas Wirth's ideas. Ideas in Rust are not new in computer science, it was more like that there was two decades of strongly typed languages not trending.
0
0
0