CompilerError: Stack too deep, try removing local variables.

原因

是一个function里面的变量 数量不能超过(16),包括了入参和返回值。

解决方法

  1. 减少方法内不必要的变量
  2. 使用结构体减少单个变量参数

参考

https://medium.com/1milliondevs/compilererror-stack-too-deep-try-removing-local-variables-solved-a6bcecc16231

版权属于:Surou

本文链接:https://www.bcskill.com/index.php/archives/1046.html

相关技术文章仅限于相关区块链底层技术研究,禁止用于非法用途,后果自负!本站严格遵守一切相关法律政策!

评论