Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4c02852

Browse files
committed
Python: add missing * (and a rename)
1 parent ecc5a4a commit 4c02852

2 files changed

Lines changed: 4 additions & 6 deletions

File tree

python/ql/src/experimental/dataflow/internal/DataFlowPublic.qll

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -178,9 +178,9 @@ class BarrierGuard extends GuardNode {
178178
/** Gets a node guarded by this guard. */
179179
final ExprNode getAGuardedNode() {
180180
exists(EssaDefinition def, ControlFlowNode node, boolean branch |
181-
AdjacentUses::aUse(def, node) and
181+
AdjacentUses::useOfDef(def, node) and
182182
this.checks(node, branch) and
183-
AdjacentUses::aUse(def, result.asCfgNode()) and
183+
AdjacentUses::useOfDef(def, result.asCfgNode()) and
184184
this.controlsBlock(result.asCfgNode().getBasicBlock(), branch)
185185
)
186186
}

python/ql/src/semmle/python/essa/SsaCompute.qll

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -506,12 +506,10 @@ private module SsaComputeImpl {
506506
* Holds if the value defined at `def` can reach `use`, possibly through phi nodes.
507507
*/
508508
cached
509-
predicate aUse(EssaDefinition def, ControlFlowNode use) {
510-
firstUse(def, use)
511-
or
509+
predicate useOfDef(EssaDefinition def, ControlFlowNode use) {
512510
exists(ControlFlowNode firstUse |
513511
firstUse(def, firstUse) and
514-
adjacentUseUse(firstUse, use)
512+
adjacentUseUse*(firstUse, use)
515513
)
516514
}
517515
}

0 commit comments

Comments
 (0)