Fix possibly effectless map emplace

This commit is contained in:
Leonardo Alt 2018-10-17 19:00:38 +02:00
parent c92d3b537d
commit 070471d8d4

View File

@ -992,13 +992,16 @@ void SMTChecker::createExpr(Expression const& _e)
solAssert(_e.annotation().type, ""); solAssert(_e.annotation().type, "");
if (hasExpr(_e)) if (hasExpr(_e))
m_expressions.at(&_e)->increaseIndex(); m_expressions.at(&_e)->increaseIndex();
auto result = newSymbolicVariable(*_e.annotation().type, "expr_" + to_string(_e.id()), *m_interface); else
m_expressions.emplace(&_e, result.second); {
if (result.first) auto result = newSymbolicVariable(*_e.annotation().type, "expr_" + to_string(_e.id()), *m_interface);
m_errorReporter.warning( m_expressions.emplace(&_e, result.second);
_e.location(), if (result.first)
"Assertion checker does not yet implement this type." m_errorReporter.warning(
); _e.location(),
"Assertion checker does not yet implement this type."
);
}
} }
void SMTChecker::defineExpr(Expression const& _e, smt::Expression _value) void SMTChecker::defineExpr(Expression const& _e, smt::Expression _value)