2 ms·
comparing it with c? thread safety maybe?
by fragmede 4mo ago
comparing it with c? thread safety maybe?
- DanielHB 4mo agoAs far as I understand co-routines help don't really help with memory shared across go-routines. They only help in the fact you need to manage spawning and joining threads, making it easier to do stuff in parallel. But they don't provide thread-safety. edit: I suppose you don't get segfaults or buffer overflows and the sort in go for accessing memory in a parallel context, you get recoverable panics. But that is still not really thread safety in my opinion, it is memory safety.
- odo1242 4mo agoThe language also does not support goroutines, locks, or channels, except through using the C threading libraries. (I think the original author meant type safety when they made that statement. Though it still doesn't make all that much sense to me)