if (compiler.getCodingConvention().isExported(var.name, s.isLocal())) {
continue;
}
// Try to look for the best shadow for the current candidate.
Assignment bestShadow = findBestShadow(s, var);
if (bestShadow == null) {
continue;
}
// The name assignment being shadowed.
Assignment localAssignment = assignments.get(var.getName());
// Only shadow if this increases the number of occurrences of the
// shadowed variable.
if (bestShadow.count < localAssignment.count) {
continue; // Hope the next local variable would have a smaller count.