From 53d4433484c33b32d4d1063330633a308c0e48dd Mon Sep 17 00:00:00 2001 From: Alex Beregszaszi Date: Wed, 30 Nov 2016 15:06:13 +0000 Subject: LLL: simplify error handling in parseLLL --- liblll/Compiler.cpp | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) (limited to 'liblll') 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(); } -- cgit v1.2.3