diff options
Diffstat (limited to 'libsolidity/inlineasm/AsmStack.cpp')
-rw-r--r-- | libsolidity/inlineasm/AsmStack.cpp | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/libsolidity/inlineasm/AsmStack.cpp b/libsolidity/inlineasm/AsmStack.cpp index 22042ada..c891678b 100644 --- a/libsolidity/inlineasm/AsmStack.cpp +++ b/libsolidity/inlineasm/AsmStack.cpp @@ -34,14 +34,18 @@ using namespace dev::solidity::assembly; bool InlineAssemblyStack::parse(const std::shared_ptr<Scanner>& _scanner) { + m_parserResult = make_shared<Block>(); Parser parser(m_errors); - m_asmBlock = parser.parse(_scanner); - return !!m_asmBlock; + auto result = parser.parse(_scanner); + if (!result) + return false; + *m_parserResult = std::move(*result); + return true; } eth::Assembly InlineAssemblyStack::assemble() { - CodeGenerator codeGen(*m_asmBlock, m_errors); + CodeGenerator codeGen(*m_parserResult, m_errors); return codeGen.assemble(); } |