forEachDepthFirstIndexed method
Takes an action for each element.
Calls action
for each element along with the index in the
iteration order.
Implementation
void forEachDepthFirstIndexed(
void Function(int index, Expression expression) action) {
var index = 0;
for (var expression in depthFirst) {
action(index, expression);
index++;
}
}