Преглед изворни кода

fix 10.6.9 wrong

cannot use i (type *Integer) as type int in argument to strconv.Itoa
Ding пре 9 година
родитељ
комит
14ce0489c8
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      eBook/10.6.md

+ 1 - 1
eBook/10.6.md

@@ -648,7 +648,7 @@ Go 不需要一个显式的类定义,如同 Java、C++、C# 等那样,相反
 ```go
 type Integer int
 func (i *Integer) String() string {
-    return strconv.Itoa(i)
+    return strconv.Itoa(int(*i))
 }
 ```