Skip to content

Commit 2b47ac8

Browse files
committed
C++: Remove superfluous inference logic.
1 parent b3cbdb5 commit 2b47ac8

File tree

1 file changed

+0
-19
lines changed

1 file changed

+0
-19
lines changed

cpp/ql/lib/semmle/code/cpp/controlflow/IRGuards.qll

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -436,25 +436,6 @@ private module LogicInput_v1 implements GuardsImpl::LogicInputSig {
436436
) {
437437
g1.(ConditionalBranchInstruction).getCondition() = g2 and
438438
v1.asBooleanValue() = v2.asBooleanValue()
439-
or
440-
exists(SwitchInstruction switch, SwitchEdge edge |
441-
g1 = switch.getSuccessor(edge) and
442-
g2 = switch.getExpression()
443-
|
444-
v1.asBooleanValue() = true and
445-
(
446-
v2.asIntValue() = edge.getValue().toInt()
447-
or
448-
v2.asConstantValue().isRange(edge.getMinValue(), edge.getMaxValue())
449-
)
450-
or
451-
v1.asBooleanValue() = false and
452-
(
453-
v2.getDualValue().asIntValue() = edge.getValue().toInt()
454-
or
455-
v2.getDualValue().asConstantValue().isRange(edge.getMinValue(), edge.getMaxValue())
456-
)
457-
)
458439
}
459440
}
460441

0 commit comments

Comments
 (0)