エントリーの編集
エントリーの編集は全ユーザーに共通の機能です。
必ずガイドラインを一読の上ご利用ください。
Different ways to pass channels as arguments in function
記事へのコメント0件
- 注目コメント
- 新着コメント
このエントリーにコメントしてみましょう。
注目コメント算出アルゴリズムの一部にLINEヤフー株式会社の「建設的コメント順位付けモデルAPI」を使用しています
- バナー広告なし
- ミュート機能あり
- ダークモード搭載
関連記事
Different ways to pass channels as arguments in function
I was reading some go code and say a few different ways to pass go channels. Maybe they are the s... I was reading some go code and say a few different ways to pass go channels. Maybe they are the same but I was wondering if there is any difference since I couldn't find documentation online: 1) func serve(ch <-chan interface{}){ //do stuff } 2) func serve(ch chan<- interface{}){ //do stuff } 3) func serve(ch chan interface{}){ //do stuff } 4) func server(ch *chan interface{}){ //do stuff} I was w