随笔分类 -  golang

摘要:type MyInterface interface{ Print() } func TestFunc(x MyInterface) {} type MyStruct struct {} func (me MyStruct) Print() {} func main() { var me MyStruct TestFunc(me) } 阅读全文
posted @ 2019-12-18 13:57 Ellen_Fu 阅读(79) 评论(0) 推荐(0)
摘要:vscode启动,出现下面提示,点安装会失败。 The "gopls" command is not available. Use "go get -v golang.org/x/tools/cmd/gopls" to install. 下面是手工解决方案: github.com中对应golang. 阅读全文
posted @ 2019-12-13 14:51 Ellen_Fu 阅读(5075) 评论(0) 推荐(0)