|
|
|
|
|
by stcredzero
3542 days ago
|
|
In most implementations, Smalltalk is compiled to bytecode, and uses late binding. It's usually run on a JIT. how would it statically enforce the equivalent of Send and Sync constraints? In some Smalltalks, normal execution is synchronous. Many of them also use read and write boundaries for various purposes. The former gives you Send and Sync constraints for free. The latter can be used in difficult edge cases. (Like when you're calling out to the OS.) |
|
Uh, no, it gives you thread safety for free.
When my comment was talking about Send and Sync I was talking about the specific way Rust's typesystem enforces thread safety. I'm not saying that other languages don't, I'm saying that Rust's method of enforcing it might be one of the few unique things it does