diff options
author | Alex Beregszaszi <alex@rtfs.hu> | 2016-11-30 23:06:13 +0800 |
---|---|---|
committer | Alex Beregszaszi <alex@rtfs.hu> | 2016-11-30 23:06:13 +0800 |
commit | 53d4433484c33b32d4d1063330633a308c0e48dd (patch) | |
tree | 1f4deb27dccf1499527c99c5ab76694aaa159dd9 | |
parent | d82eac3fed6547ddcaac8ecccb15c7f7eaa74d16 (diff) | |
download | dexon-solidity-53d4433484c33b32d4d1063330633a308c0e48dd.tar.gz dexon-solidity-53d4433484c33b32d4d1063330633a308c0e48dd.tar.zst dexon-solidity-53d4433484c33b32d4d1063330633a308c0e48dd.zip |
LLL: simplify error handling in parseLLL
-rw-r--r-- | liblll/Compiler.cpp | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/liblll/Compiler.cpp b/liblll/Compiler.cpp index 73a82a35..cd909f34 100644 --- a/liblll/Compiler.cpp +++ b/liblll/Compiler.cpp @@ -99,7 +99,6 @@ std::string dev::eth::compileLLLToAsm(std::string const& _src, bool _opt, std::v string dev::eth::parseLLL(string const& _src) { - bool failed = false; sp::utree o; try @@ -108,19 +107,12 @@ string dev::eth::parseLLL(string const& _src) } catch (...) { - failed = true; + killBigints(o); + return string(); } ostringstream ret; debugOutAST(ret, o); killBigints(o); - - if (failed) - { - return string(); - } - else - { - return ret.str(); - } + return ret.str(); } |