Skip to content

Commit

Permalink
Fix complexity comment
Browse files Browse the repository at this point in the history
  • Loading branch information
findepi committed Jan 29, 2025
1 parent 6fe2b99 commit ab572c9
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1385,7 +1385,7 @@ impl<S: SimplifyInfo> TreeNodeRewriter for Simplifier<'_, S> {
when_then_expr,
else_expr,
}) if !when_then_expr.is_empty()
&& when_then_expr.len() < 3 // The rewrite is O(n!) so limit to small number
&& when_then_expr.len() < 3 // The rewrite is O(n²) so limit to small number
&& info.is_boolean_type(&when_then_expr[0].1)? =>
{
// String disjunction of all the when predicates encountered so far. Not nullable.
Expand Down

0 comments on commit ab572c9

Please sign in to comment.