Skip to content

Commit b25c536

Browse files
committed
C#: Update read steps for tuples as they are now part of the PatternDefinition.
1 parent b76b090 commit b25c536

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎csharp/ql/lib/semmle/code/csharp/dataflow/internal/DataFlowPrivate.qll‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2242,8 +2242,8 @@ private predicate readContentStep(Node node1, Content c, Node node2) {
22422242
)
22432243
or
22442244
// item = variable in node1 = (..., variable, ...) in a case/is var (..., ...)
2245-
isPatternExprDescendant(te) and
2246-
exists(AssignableDefinitions::LocalVariableDefinition lvd |
2245+
te instanceof TuplePatternExpr and
2246+
exists(AssignableDefinitions::PatternDefinition lvd |
22472247
node2.(AssignableDefinitionNode).getDefinition() = lvd and
22482248
lvd.getDeclaration() = item
22492249
)

0 commit comments

Comments
 (0)