Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Not really possible in a systems level programming language like rust/zig/C. There really is only one address space for the process... and if you have the ability to manipulate it you have global variables.

There's lots of interest things you could do with a rust like (in terms of correctness properties) high level language, and getting rid of global variables might be one of them (though I can see arguments in both directions). Hopefully someone makes a good one some day.





> Not really possible in a systems level programming language like rust/zig/C. There really is only one address space for the process... and if you have the ability to manipulate it you have global variables.

doesn't imply you have to expose it as a global mutable variable




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: