Fixing signedness conversion warnings in libevmasm

Co-authored-by: Harikrishnan Mulackal <webmail.hari@gmail.com>
This commit is contained in:
Djordje Mijovic
2020-06-03 13:25:43 +02:00
co-authored by Harikrishnan Mulackal
parent b9f2697a3c
commit e4e3f49844
15 changed files with 98 additions and 93 deletions
+4 -3
View File
@@ -63,8 +63,9 @@ bool BlockDeduplicator::deduplicate()
if (_j < m_items.size() && m_items.at(_j).type() == Tag)
pushSecondTag = m_items.at(_j).pushTag();
BlockIterator first{m_items.begin() + _i, m_items.end(), &pushFirstTag, &pushSelf};
BlockIterator second{m_items.begin() + _j, m_items.end(), &pushSecondTag, &pushSelf};
using diff_type = BlockIterator::difference_type;
BlockIterator first{m_items.begin() + diff_type(_i), m_items.end(), &pushFirstTag, &pushSelf};
BlockIterator second{m_items.begin() + diff_type(_j), m_items.end(), &pushSecondTag, &pushSelf};
BlockIterator end{m_items.end(), m_items.end()};
if (first != end && (*first).type() == Tag)
@@ -120,7 +121,7 @@ bool BlockDeduplicator::applyTagReplacement(
if (it != _replacements.end())
{
changed = true;
item.setPushTagSubIdAndTag(subId, size_t(it->second));
item.setPushTagSubIdAndTag(subId, static_cast<size_t>(it->second));
}
}
return changed;