Skip to content

Commit fae915b

Browse files
committed
Python: QL doc
1 parent 551ae42 commit fae915b

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

python/ql/src/semmle/python/Comprehensions.qll

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,18 +7,19 @@ abstract class Comp extends Expr {
77
/** Gets the iterable of this set comprehension. */
88
abstract Expr getIterable();
99

10-
/** Gets the iteration variable for the nth innermost generator of this list comprehension */
10+
/** Gets the iteration variable for the nth innermost generator of this comprehension. */
1111
Variable getIterationVariable(int n) {
1212
result.getAnAccess() = this.getNthInnerLoop(n).getTarget()
1313
}
1414

15+
/** Gets the nth innermost For expression of this comprehension. */
1516
For getNthInnerLoop(int n) {
1617
n = 0 and result = this.getFunction().getStmt(0)
1718
or
1819
result = this.getNthInnerLoop(n - 1).getStmt(0)
1920
}
2021

21-
/** Gets the iteration variable for a generator of this list comprehension */
22+
/** Gets the iteration variable for a generator of this list comprehension. */
2223
Variable getAnIterationVariable() { result = this.getIterationVariable(_) }
2324

2425
/** Gets the scope in which the body of this list comprehension evaluates. */

0 commit comments

Comments
 (0)