From 5ac7620045012c2ed565b81978dc35f5f83f7eea Mon Sep 17 00:00:00 2001 From: Daniel Kirchner Date: Mon, 10 Dec 2018 04:25:51 +0100 Subject: Use C++ user-defined literals for creating YulString constants. --- libyul/optimiser/MainFunction.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'libyul/optimiser/MainFunction.cpp') diff --git a/libyul/optimiser/MainFunction.cpp b/libyul/optimiser/MainFunction.cpp index 63eea2db..fabbf66f 100644 --- a/libyul/optimiser/MainFunction.cpp +++ b/libyul/optimiser/MainFunction.cpp @@ -40,12 +40,12 @@ void MainFunction::operator()(Block& _block) for (size_t i = 1; i < _block.statements.size(); ++i) assertThrow(_block.statements.at(i).type() == typeid(FunctionDefinition), OptimizerException, ""); /// @todo this should handle scopes properly and instead of an assertion it should rename the conflicting function - assertThrow(NameCollector(_block).names().count(YulString{"main"}) == 0, OptimizerException, ""); + assertThrow(NameCollector(_block).names().count("main"_yulstring) == 0, OptimizerException, ""); Block& block = boost::get(_block.statements[0]); FunctionDefinition main{ block.location, - YulString{"main"}, + "main"_yulstring, {}, {}, std::move(block) -- cgit v1.2.3