i got errors from building source: 35%] Building CXX object libyul/CMakeFiles/yul.dir/optimiser/NameCollector.cpp.o
/Users/hesdx/install/solidity/libyul/optimiser/NameCollector.cpp:38:18: error: loop variable 'arg' of type
'const yul::TypedName' creates a copy from type 'const yul::TypedName' [-Werror,-Wrange-loop-analysis]
for (auto const arg: _funDef.parameters)
^
/Users/hesdx/install/solidity/libyul/optimiser/NameCollector.cpp:38:7: note: use reference type
'const yul::TypedName &' to prevent copying
for (auto const arg: _funDef.parameters)
^~~~~~~~~~~~~~~
&
/Users/hesdx/install/solidity/libyul/optimiser/NameCollector.cpp:40:18: error: loop variable 'ret' of type
'const yul::TypedName' creates a copy from type 'const yul::TypedName' [-Werror,-Wrange-loop-analysis]
for (auto const ret: _funDef.returnVariables)
^
/Users/hesdx/install/solidity/libyul/optimiser/NameCollector.cpp:40:7: note: use reference type
'const yul::TypedName &' to prevent copying
for (auto const ret: _funDef.returnVariables)
^~~~~~~~~~~~~~~
&
2 errors generated.
make[2]: *** [libyul/CMakeFiles/yul.dir/optimiser/NameCollector.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [libyul/CMakeFiles/yul.dir/all] Error 2
make: *** [all] Error 2
dapdefi:solidity apple$ solc
solc, the Solidity commandline compiler.

Sep 25, 2020, 9:25 AM

© 2024 Draquery.com All rights reserved.