mirror of
https://github.com/github/codeql.git
synced 2026-05-03 04:39:29 +02:00
Revert "Fix ExprStmt and StmtExpr in Boolean context"
This reverts commit 8a42837578e1c4361ed25682312ea5497ad0a12e.
This commit is contained in:
@@ -286,7 +286,7 @@ private module ControlFlowGraphImpl {
|
||||
* That is, contexts where the control-flow edges depend on `value` given that `b` ends
|
||||
* with a `booleanCompletion(value, _)`.
|
||||
*/
|
||||
private predicate inBooleanContext(ControlFlowNode b) {
|
||||
private predicate inBooleanContext(Expr b) {
|
||||
exists(LogicExpr logexpr |
|
||||
logexpr.(BinaryExpr).getLeftOperand() = b
|
||||
or
|
||||
@@ -316,10 +316,6 @@ private module ControlFlowGraphImpl {
|
||||
inBooleanContext(whenexpr) and
|
||||
whenexpr.getBranch(_).getAResult() = b
|
||||
)
|
||||
or
|
||||
inBooleanContext(b.(ExprStmt).getExpr())
|
||||
or
|
||||
inBooleanContext(b.(StmtExpr).getStmt())
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user