Skip to content

Commit 4433cc0

Browse files
committed
Python: Document MultiAssignmentDefinition.indexOf
1 parent 5c3109a commit 4433cc0

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

  • python/ql/src/semmle/python/essa

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

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -609,6 +609,11 @@ class MultiAssignmentDefinition extends EssaNodeDefinition {
609609
)
610610
}
611611

612+
/**
613+
* Holds if `this` has index `index` in `lhs`.
614+
*
615+
* For example, for `a,b = t` the call `b.indexOf(1, t)` holds.
616+
*/
612617
predicate indexOf(int index, SequenceNode lhs) {
613618
SsaSource::multi_assignment_definition(this.getSourceVariable(), this.getDefiningNode(), index, lhs)
614619
}

0 commit comments

Comments
 (0)