mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Replace boost::variant by std::variant in libyul
This commit is contained in:
@@ -35,6 +35,7 @@
|
||||
#include <boost/algorithm/cxx11/all_of.hpp>
|
||||
|
||||
#include <ostream>
|
||||
#include <variant>
|
||||
|
||||
using namespace std;
|
||||
using namespace dev;
|
||||
@@ -161,9 +162,9 @@ void Interpreter::operator()(Block const& _block)
|
||||
openScope();
|
||||
// Register functions.
|
||||
for (auto const& statement: _block.statements)
|
||||
if (statement.type() == typeid(FunctionDefinition))
|
||||
if (holds_alternative<FunctionDefinition>(statement))
|
||||
{
|
||||
FunctionDefinition const& funDef = boost::get<FunctionDefinition>(statement);
|
||||
FunctionDefinition const& funDef = std::get<FunctionDefinition>(statement);
|
||||
solAssert(!m_scopes.back().count(funDef.name), "");
|
||||
m_scopes.back().emplace(funDef.name, &funDef);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user