diff --git a/libsolidity/interface/StandardCompiler.cpp b/libsolidity/interface/StandardCompiler.cpp index 5b033dfce..6ab9789fc 100644 --- a/libsolidity/interface/StandardCompiler.cpp +++ b/libsolidity/interface/StandardCompiler.cpp @@ -437,7 +437,7 @@ boost::variant parseOptimizerSettings(Json::Valu return *error; } } - return std::move(settings); + return { std::move(settings) }; } } @@ -663,7 +663,7 @@ boost::variant StandardCompile ret.outputSelection = std::move(outputSelection); - return std::move(ret); + return { std::move(ret) }; } Json::Value StandardCompiler::compileSolidity(StandardCompiler::InputsAndSettings _inputsAndSettings) diff --git a/libyul/backends/wasm/EWasmCodeTransform.cpp b/libyul/backends/wasm/EWasmCodeTransform.cpp index a67bd2c3a..ea8447f33 100644 --- a/libyul/backends/wasm/EWasmCodeTransform.cpp +++ b/libyul/backends/wasm/EWasmCodeTransform.cpp @@ -63,7 +63,7 @@ wasm::Expression EWasmCodeTransform::generateMultiAssignment( wasm::LocalAssignment assignment{move(_variableNames.front()), std::move(_firstValue)}; if (_variableNames.size() == 1) - return move(assignment); + return { std::move(assignment) }; wasm::Block block; block.statements.emplace_back(move(assignment)); @@ -72,7 +72,7 @@ wasm::Expression EWasmCodeTransform::generateMultiAssignment( move(_variableNames.at(i)), make_unique(wasm::GlobalVariable{m_globalVariables.at(i - 1).variableName}) }); - return move(block); + return { std::move(block) }; } wasm::Expression EWasmCodeTransform::operator()(VariableDeclaration const& _varDecl) @@ -192,7 +192,7 @@ wasm::Expression EWasmCodeTransform::operator()(Switch const& _switch) *currentBlock += visit(c.body.statements); } } - return move(block); + return { std::move(block) }; } wasm::Expression EWasmCodeTransform::operator()(FunctionDefinition const&) @@ -224,7 +224,7 @@ wasm::Expression EWasmCodeTransform::operator()(ForLoop const& _for) wasm::Block breakBlock{breakLabel, {}}; breakBlock.statements.emplace_back(move(loop)); - return move(breakBlock); + return { std::move(breakBlock) }; } wasm::Expression EWasmCodeTransform::operator()(Break const&) diff --git a/libyul/optimiser/ForLoopInitRewriter.cpp b/libyul/optimiser/ForLoopInitRewriter.cpp index 6650e49dd..2de0a662f 100644 --- a/libyul/optimiser/ForLoopInitRewriter.cpp +++ b/libyul/optimiser/ForLoopInitRewriter.cpp @@ -38,7 +38,7 @@ void ForLoopInitRewriter::operator()(Block& _block) vector rewrite; swap(rewrite, forLoop.pre.statements); rewrite.emplace_back(move(forLoop)); - return std::move(rewrite); + return { std::move(rewrite) }; } else { diff --git a/libyul/optimiser/SSATransform.cpp b/libyul/optimiser/SSATransform.cpp index 625d82bdc..68726c486 100644 --- a/libyul/optimiser/SSATransform.cpp +++ b/libyul/optimiser/SSATransform.cpp @@ -106,7 +106,7 @@ void SSATransform::operator()(Block& _block) }); } boost::get(statements.front()).variables = std::move(newVariables); - return std::move(statements); + return { std::move(statements) }; } else if (_s.type() == typeid(Assignment)) { @@ -133,7 +133,7 @@ void SSATransform::operator()(Block& _block) }); } boost::get(statements.front()).variables = std::move(newVariables); - return std::move(statements); + return { std::move(statements) }; } else visit(_s);