| Index: pkg/analysis_server/lib/src/services/completion/suggestion_builder.dart
|
| diff --git a/pkg/analysis_server/lib/src/services/completion/suggestion_builder.dart b/pkg/analysis_server/lib/src/services/completion/suggestion_builder.dart
|
| index 9dfdf2f8df35d350b576ed7b87b38a50a599a965..80ddd8560414003336112be61692682d28e3cd84 100644
|
| --- a/pkg/analysis_server/lib/src/services/completion/suggestion_builder.dart
|
| +++ b/pkg/analysis_server/lib/src/services/completion/suggestion_builder.dart
|
| @@ -157,12 +157,13 @@ visitInheritedTypeNames(ClassDeclaration node, void inherited(String name)) {
|
| /**
|
| * Starting with the given class node, traverse the inheritence hierarchy
|
| * calling the given functions with each non-null non-empty inherited class
|
| - * declaration. For each locally defined class declaration, call [local].
|
| + * declaration. For each locally defined declaration, call [localDeclaration].
|
| * For each class identifier in the hierarchy that is not defined locally,
|
| - * call the [imported] function.
|
| + * call the [importedTypeName] function.
|
| */
|
| void visitInheritedTypes(ClassDeclaration node,
|
| - void local(ClassDeclaration classNode), void imported(String typeName)) {
|
| + {void localDeclaration(ClassDeclaration classNode),
|
| + void importedTypeName(String typeName)}) {
|
| CompilationUnit unit = node.getAncestor((p) => p is CompilationUnit);
|
| List<ClassDeclaration> todo = new List<ClassDeclaration>();
|
| todo.add(node);
|
| @@ -181,10 +182,14 @@ void visitInheritedTypes(ClassDeclaration node,
|
| return false;
|
| }, orElse: () => null);
|
| if (classNode is ClassDeclaration) {
|
| - local(classNode);
|
| + if (localDeclaration != null) {
|
| + localDeclaration(classNode);
|
| + }
|
| todo.add(classNode);
|
| } else {
|
| - imported(name);
|
| + if (importedTypeName != null) {
|
| + importedTypeName(name);
|
| + }
|
| }
|
| }
|
| });
|
|
|