aboutsummaryrefslogtreecommitdiffstats
path: root/libyul/optimiser/SimplificationRules.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'libyul/optimiser/SimplificationRules.cpp')
-rw-r--r--libyul/optimiser/SimplificationRules.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/libyul/optimiser/SimplificationRules.cpp b/libyul/optimiser/SimplificationRules.cpp
index 4d0468c7..aca943b0 100644
--- a/libyul/optimiser/SimplificationRules.cpp
+++ b/libyul/optimiser/SimplificationRules.cpp
@@ -209,6 +209,7 @@ u256 Pattern::d() const
{
Literal const& literal = boost::get<Literal>(matchGroupValue());
assertThrow(literal.kind == assembly::LiteralKind::Number, OptimizerException, "");
+ assertThrow(isValidDecimal(literal.value) || isValidHex(literal.value), OptimizerException, "");
return u256(literal.value);
}