Fix YulUtilFunctions::negateNumberWrappingFunction

This commit is contained in:
Alex Beregszaszi 2021-01-13 14:34:48 +00:00
parent fe344ed6e5
commit c15c6d26b7
2 changed files with 3 additions and 1 deletions

View File

@ -3765,7 +3765,7 @@ string YulUtilFunctions::negateNumberWrappingFunction(Type const& _type)
return m_functionCollector.createFunction(functionName, [&]() {
return Whiskers(R"(
function <functionName>(value) -> ret {
value := <cleanupFunction>(sub(0, value)))
ret := <cleanupFunction>(sub(0, value))
}
)")
("functionName", functionName)

View File

@ -6,5 +6,7 @@ contract test {
}
}
// ====
// compileViaYul: also
// ----
// f() -> true