3 ms·
That is very nearly what they are. The compiler actually just transforms everything channel related into function calls within the runtime package. The majorit
by amscanne 10y ago
That is very nearly what they are.
The compiler actually just transforms everything channel related into function calls within the runtime package. The majority (probably > 99%) of the implementation of channels and select is Go itself.
E.g., see: https://golang.org/src/runtime/chan.go https://golang.org/src/runtime/chan.go