我如何解决这个问题?

布鲁克约纳斯

这是因为函数错过了返回类型。

 Future<bool> func1() {
  // you logic
  return true <-- // return bool value should be specified here
 }

如果你想要没有返回类型的函数

 Future<void> func2() {
   // you logic
     <-- //there will not be return type here 
 }

本文收集自互联网,转载请注明来源。

如有侵权,请联系 [email protected] 删除。

编辑于
0

我来说两句

0 条评论
登录 后参与评论

相关文章