From 8d85f7803105e46e869b0930024f04c89b876815 Mon Sep 17 00:00:00 2001 From: htlhenry Date: Wed, 15 Feb 2017 17:39:44 +0800 Subject: [PATCH] =?UTF-8?q?go=E5=85=B3=E9=94=AE=E5=AD=97=E4=B9=8B=E5=90=8E?= =?UTF-8?q?=E7=9A=84=E5=8C=BF=E5=90=8D=E5=87=BD=E6=95=B0=E9=9C=80=E8=A6=81?= =?UTF-8?q?=E5=8A=A0=E4=B8=8A()?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit go关键字之后的匿名函数需要加上() --- eBook/14.2.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eBook/14.2.md b/eBook/14.2.md index 1080b3a..e162b2d 100644 --- a/eBook/14.2.md +++ b/eBook/14.2.md @@ -281,7 +281,7 @@ ch := make(chan int) go func(){ // doSomething ch <- 1 // Send a signal; value does not matter -} +}() doSomethingElseForAWhile() <- ch // Wait for goroutine to finish; discard sent value. ```