3 ms·
> Even further, message passing! I really like how Go does message passing, and other than channels being first class types, I don't think that's really the "k
by burntsushi 14y ago
> Even further, message passing!
I really like how Go does message passing, and other than channels being first class types, I don't think that's really the "killer feature" of Go. The killer feature is that goroutines are green threads, scheduled in M:N fashion on to OS threads. This encourages concurrent programming because spinning up a goroutine is comparatively cheap to spinning up an OS thread. It's difficult to do this kind of programming in most other languages (sans Erlang, Rust and Haskell).
Joe Armstrong made this argument years ago. He compared the limited ability to start processes in most languages as being similar to limiting how many objects you could create in your program.
If you want to see examples of concurrent programming in Go, go straight to the source: http://golang.org http://golang.org --- The tour is good, there are some codewalks, talks, articles, etc.