by tarkin2 · 5y ago · 0 comments
[edit] Sorry, edited before there was a reply. You're very fast!
At the least I'd say he's over optimistic, but the work is getting done.
This is a frequently asked question, so I had it covered.
Things V improves on Go:
Awesome work, sure it will get there either way :)
Concurrency is WIP, and will be the main feature of 0.3.
We already have channels, locks, and thread safe typed arrays/maps.
1. Will they be as heavy as Go's ? Go has 2 mutexes and some other fluff
2. Are they "close-safe" like, if I send something to the channel, and it is nil or closed, will it panic crash or stuck forever like Go does, or V is trying to be "panic-free"? Will "prohibited" operation return an error or panic/stuck?
3. If channels are closeable, will I be able to close them twice without panic (closing closed door might creak, but IMHO should not burn the house down...)
(At some point in the past I did suggest adding an error to channel operations so it will not panic if I am ready to intercept an error, but that was rejected)