Exit StackToMemoryMover early, if there are no variables to be moved.

This commit is contained in:
Daniel Kirchner 2020-10-06 13:02:51 +02:00
parent a59bf01ebd
commit 0b199f3372

View File

@ -63,6 +63,12 @@ void StackToMemoryMover::run(
Block& _block
)
{
if (!_numRequiredSlots)
{
yulAssert(_memorySlots.empty(), "");
return;
}
auto const* evmDialect = dynamic_cast<EVMDialect const*>(&_context.dialect);
yulAssert(
evmDialect && evmDialect->providesObjectAccess(),