Improve FunctionSelector helpers

This commit is contained in:
Alex Beregszaszi
2022-09-27 17:58:32 +02:00
parent 311b2054af
commit 725253551e
23 changed files with 106 additions and 50 deletions
+1 -1
View File
@@ -889,7 +889,7 @@ void ArrayUtils::popStorageArrayElement(ArrayType const& _type) const
}
sstore(ref, slot_value)
})");
code("panicSelector", util::selectorFromSignature("Panic(uint256)").str());
code("panicSelector", util::selectorFromSignatureU256("Panic(uint256)").str());
code("emptyArrayPop", to_string(unsigned(util::PanicCode::EmptyArrayPop)));
m_context.appendInlineAssembly(code.render(), {"ref", "slot_value", "length"});
m_context << Instruction::POP << Instruction::POP << Instruction::POP;