原文:syntax error: non-declaration statement outside function body

在函数外部使用形如:name: mark 这样语句会出现 syntax error: non declaration statement outside function body ...

2019-01-29 21:35 0 806 推荐指数:

查看详情

non-declaration statement outside function body错误

这个觉得Google出来的好多说的不是特别清楚,后来在StackOverflow上看到一个答案:the tour of go解释为什么出这个错: https://tour.golang.org/bas ...

Mon Oct 26 23:57:00 CST 2020 0 645
 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM