Skip to content

Commit 6b78d33

Browse files
committed
simplify code
Signed-off-by: Weizhen Wang <[email protected]>
1 parent 9c2dbc5 commit 6b78d33

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

pkg/expression/constant_propagation.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -440,7 +440,9 @@ func (s *propConstSolver) propagateColumnEQ() {
440440
// a = b and ( a = b or c =d ) => a = b and ( true or c = d )
441441
//
442442
// True can be removed in the shortCircuitLogicalConstants.
443-
continue
443+
if _, ok := s.conditions[k].(*Constant); ok {
444+
continue
445+
}
444446
}
445447
cond := s.conditions[k]
446448
replaced, _, newExpr := tryToReplaceCond(s.ctx, coli, colj, cond, false)

0 commit comments

Comments
 (0)