mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-06-06 17:26:01 +02:00
Bug 488904 - Performance regression of code completion due to parameter
guessing Code cleanup. Change-Id: Idf8fadddef683bd1161a0d60333e47cd2437d730
This commit is contained in:
parent
9240257992
commit
1a0c51205e
1 changed files with 2 additions and 8 deletions
|
@ -703,7 +703,7 @@ public class DOMCompletionProposalComputer extends ParsingBasedProposalComputer
|
|||
|
||||
// Get all variables declared in the translation unit.
|
||||
final Set<IBinding> declaredVariables = new HashSet<>();
|
||||
ast.accept(new NameVisitor() {
|
||||
ast.accept(new ASTVisitor(true) {
|
||||
@Override
|
||||
public int visit(IASTName name) {
|
||||
if (getNodeOffset(name) >= statementOffset)
|
||||
|
@ -715,7 +715,7 @@ public class DOMCompletionProposalComputer extends ParsingBasedProposalComputer
|
|||
declaredVariables.add(binding);
|
||||
}
|
||||
}
|
||||
return PROCESS_CONTINUE;
|
||||
return PROCESS_SKIP; // Do non visit internals of qualified names.
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -954,10 +954,4 @@ public class DOMCompletionProposalComputer extends ParsingBasedProposalComputer
|
|||
private static IPreferenceStore getPreferenceStore() {
|
||||
return CUIPlugin.getDefault().getPreferenceStore();
|
||||
}
|
||||
|
||||
private static abstract class NameVisitor extends ASTVisitor {
|
||||
NameVisitor() {
|
||||
shouldVisitNames = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue