CodeQL library for C#
codeql/csharp-all 0.8.12 (changelog, source)
Search

Member predicate ForeachStmt::getVariable

Gets the ith local variable of this foreach loop.

For example, a is the 0th local variable in

foreach ((int a, int b) in items) {
  ...
}
LocalVariable getVariable(int i)