| Index: pkg/analysis_server/lib/src/services/completion/local_computer.dart
|
| diff --git a/pkg/analysis_server/lib/src/services/completion/local_computer.dart b/pkg/analysis_server/lib/src/services/completion/local_computer.dart
|
| index fdbb38c8bda717f8ebafa96edddb9e2aa91eb00a..8f70ab8e97f461911c1171863ab08519a38acb36 100644
|
| --- a/pkg/analysis_server/lib/src/services/completion/local_computer.dart
|
| +++ b/pkg/analysis_server/lib/src/services/completion/local_computer.dart
|
| @@ -104,18 +104,25 @@ class LocalComputer extends DartCompletionComputer {
|
| new _ConstructorVisitor(request).visit(request.node);
|
| }
|
|
|
| - // If the unit is not a part and does not reference any parts
|
| - // then work is complete
|
| - return !request.unit.directives.any((Directive directive) =>
|
| - directive is PartOfDirective || directive is PartDirective);
|
| + // If target is an argument in an argument list
|
| + // then suggestions may need to be adjusted
|
| + return request.target.argIndex == null;
|
| }
|
|
|
| @override
|
| Future<bool> computeFull(DartCompletionRequest request) {
|
| - // TODO: implement computeFull
|
| - // include results from part files that are included in the library
|
| + _updateSuggestions(request);
|
| return new Future.value(false);
|
| }
|
| +
|
| + /**
|
| + * If target is a function argument, suggest identifiers not invocations
|
| + */
|
| + void _updateSuggestions(DartCompletionRequest request) {
|
| + if (request.target.isFunctionalArgument()) {
|
| + request.convertInvocationsToIdentifiers();
|
| + }
|
| + }
|
| }
|
|
|
| /**
|
|
|