Skip to content

Commit e50a235

Browse files
committed
C#: Fix test.
1 parent d0eb9c9 commit e50a235

File tree

1 file changed

+4
-10
lines changed

1 file changed

+4
-10
lines changed

csharp/ql/test/library-tests/dataflow/defuse/useUseEquivalence.ql

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -32,17 +32,11 @@ private TLocalScopeVariableReadOrSsaDef getANextReadOrDef(TLocalScopeVariableRea
3232
result = TLocalScopeVariableRead(read.getANextRead())
3333
or
3434
not exists(read.getANextRead()) and
35-
exists(Ssa::Definition ssaDef, Ssa::PhiNode phi, ControlFlowNode cfn, BasicBlock bb, int i |
36-
ssaDef.getARead() = read
37-
|
35+
exists(Ssa::Definition ssaDef, Ssa::PhiNode phi, BasicBlock bb |
36+
ssaDef.getARead() = read and
3837
phi.getAnInput() = ssaDef and
39-
phi.definesAt(_, bb, i) and
40-
cfn = read.getAReachableElement().getAControlFlowNode() and
41-
(
42-
cfn = bb.getNode(i)
43-
or
44-
cfn = bb.getFirstNode() and i < 0
45-
) and
38+
phi.definesAt(_, bb, _) and
39+
read.getBasicBlock().getASuccessor+() = bb and
4640
result = TSsaDefinition(phi)
4741
)
4842
)

0 commit comments

Comments
 (0)