1
0
mirror of https://github.com/chai2010/advanced-go-programming-book.git synced 2025-05-24 12:32:21 +00:00

Merge pull request #1 from bcb51/bcb51-patch-1

语法错误
This commit is contained in:
bcb51 2018-01-04 12:57:44 +08:00 committed by GitHub
commit ba21853a78
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -301,13 +301,13 @@ func main() {
p.Publish("hello, golang!") p.Publish("hello, golang!")
go func() { go func() {
for _, msg := all { for msg := range all {
fmt.Println("all:", msg) fmt.Println("all:", msg)
} }
} () } ()
go func() { go func() {
for _, msg := golang { for msg := range golang {
fmt.Println("golang:", msg) fmt.Println("golang:", msg)
} }
} () } ()