We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
go version go1.12.6 windows/amd64 执行5.6节中redis的代码时报错:
go run .\redisin.go # command-line-arguments .\redisin.go:42:5: syntax error: unexpected newline, expecting comma or }
查询一番发现
func newPool(server string) *redis.Pool { return &redis.Pool{ MaxIdle: 3, IdleTimeout: 240 * time.Second, Dial: func() (redis.Conn, error) { c, err := redis.Dial("tcp", server) if err != nil { return nil, err } return c, err }, TestOnBorrow: func(c redis.Conn, t time.Time) error { _, err := c.Do("PING") return err }**,** //在多行 array、slice、map 语句中缺少 , 号 单行中可以省略但是多行不能省略 } }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
go version go1.12.6 windows/amd64
执行5.6节中redis的代码时报错:
查询一番发现
The text was updated successfully, but these errors were encountered: