cannot convert (type interface {}) to type int: need type assertion

                問題:  在使用interface表示任何類型時,若是要將interface轉爲某一類型,直接強制轉換是不行的,例如:golang var t interface{} = "abc".net s := string(t) 1 2 3 4 cannot convert t(type interface {}) to type string: need type ass
相關文章
相關標籤/搜索