File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -13,6 +13,7 @@ Compiler Features:
1313
1414Bugfixes:
1515* Yul EVM Code Transform: Improve stack shuffler performance by fixing a BFS deduplication issue.
16+ * Yul IR Code Generation: Remove custom error arguments of ` require ` when option ` revert-strings=strip ` is selected.
1617
1718
1819### 0.8.34 (2026-02-18)
Original file line number Diff line number Diff line change @@ -1158,10 +1158,7 @@ void IRGeneratorForStatements::endVisit(FunctionCall const& _functionCall)
11581158 solAssert (arguments.size () > 0 , " Expected at least one parameter for require/assert" );
11591159 solAssert (arguments.size () <= 2 , " Expected no more than two parameters for require/assert" );
11601160
1161- Type const * messageArgumentType =
1162- arguments.size () > 1 && m_context.revertStrings () != RevertStrings::Strip ?
1163- arguments[1 ]->annotation ().type :
1164- nullptr ;
1161+ Type const * messageArgumentType = arguments.size () > 1 ? arguments[1 ]->annotation ().type : nullptr ;
11651162
11661163 auto const * magicType = dynamic_cast <MagicType const *>(messageArgumentType);
11671164 if (magicType && magicType->kind () == MagicType::Kind::Error)
@@ -1175,6 +1172,8 @@ void IRGeneratorForStatements::endVisit(FunctionCall const& _functionCall)
11751172 }
11761173 else
11771174 {
1175+ if (m_context.revertStrings () == RevertStrings::Strip)
1176+ messageArgumentType = nullptr ;
11781177 ASTPointer<Expression const > stringArgumentExpression = messageArgumentType ? arguments[1 ] : nullptr ;
11791178 std::string requireOrAssertFunction = m_utils.requireOrAssertFunction (
11801179 functionType->kind () == FunctionType::Kind::Assert,
You can’t perform that action at this time.
0 commit comments