| Index: pkg/analysis_server/lib/src/domain_execution.dart
|
| diff --git a/pkg/analysis_server/lib/src/domain_execution.dart b/pkg/analysis_server/lib/src/domain_execution.dart
|
| index 29449c5b3fa450b6132c75885b2765fa63148135..dfdd2bd9c4457b5dd43fa57f1d87657e172f3f3f 100644
|
| --- a/pkg/analysis_server/lib/src/domain_execution.dart
|
| +++ b/pkg/analysis_server/lib/src/domain_execution.dart
|
| @@ -159,20 +159,25 @@ class ExecutionDomainHandler implements RequestHandler {
|
| * Implement the 'execution.setSubscriptions' request.
|
| */
|
| Response setSubscriptions(Request request) {
|
| - List<ExecutionService> subscriptions =
|
| - new ExecutionSetSubscriptionsParams.fromRequest(request).subscriptions;
|
| - if (subscriptions.contains(ExecutionService.LAUNCH_DATA)) {
|
| - if (onFileAnalyzed == null) {
|
| - onFileAnalyzed = server.onFileAnalyzed.listen(_fileAnalyzed);
|
| - _reportCurrentFileStatus();
|
| - }
|
| + if (server.options.enableNewAnalysisDriver) {
|
| + // Under the analysis driver, setSubscriptions() becomes a no-op.
|
| + return new ExecutionSetSubscriptionsResult().toResponse(request.id);
|
| } else {
|
| - if (onFileAnalyzed != null) {
|
| - onFileAnalyzed.cancel();
|
| - onFileAnalyzed = null;
|
| + List<ExecutionService> subscriptions =
|
| + new ExecutionSetSubscriptionsParams.fromRequest(request).subscriptions;
|
| + if (subscriptions.contains(ExecutionService.LAUNCH_DATA)) {
|
| + if (onFileAnalyzed == null) {
|
| + onFileAnalyzed = server.onFileAnalyzed.listen(_fileAnalyzed);
|
| + _reportCurrentFileStatus();
|
| + }
|
| + } else {
|
| + if (onFileAnalyzed != null) {
|
| + onFileAnalyzed.cancel();
|
| + onFileAnalyzed = null;
|
| + }
|
| }
|
| + return new ExecutionSetSubscriptionsResult().toResponse(request.id);
|
| }
|
| - return new ExecutionSetSubscriptionsResult().toResponse(request.id);
|
| }
|
|
|
| void _fileAnalyzed(ChangeNotice notice) {
|
|
|