mirror of
https://github.com/unknwon/the-way-to-go_ZH_CN.git
synced 2025-08-12 03:06:41 +08:00
改正变量名
This commit is contained in:
@@ -93,8 +93,8 @@ func main() {
|
|||||||
|
|
||||||
// NOT OK
|
// NOT OK
|
||||||
z := make(Bar) // 编译错误:cannot make type Bar
|
z := make(Bar) // 编译错误:cannot make type Bar
|
||||||
(*y).thingOne = "hello"
|
(*z).thingOne = "hello"
|
||||||
(*y).thingTwo = 1
|
(*z).thingTwo = 1
|
||||||
|
|
||||||
// OK
|
// OK
|
||||||
x := make(Foo)
|
x := make(Foo)
|
||||||
|
Reference in New Issue
Block a user