visitVarUsage method
void
visitVarUsage(
- VarUsage node
)
override
Implementation
@override
void visitVarUsage(VarUsage node) {
assert(_currIndex != -1);
assert(_currExpressions != null);
if (varUsages.containsKey(node.name)) {
var expressions = varUsages[node.name];
var allIndexes = expressions![_currExpressions];
if (allIndexes == null) {
_addExpression(expressions);
} else {
allIndexes.add(_currIndex);
}
} else {
var newExpressions = <Expressions, Set<int>>{};
_addExpression(newExpressions);
varUsages[node.name] = newExpressions;
}
super.visitVarUsage(node);
}