Skip to content

Commit e97f1bd

Browse files
scheglovcommit-bot@chromium.org
authored andcommitted
Switch analysis_server to language 2.12, so null safety, but opt-out files.
This should allow doing partial migration, specifically protocol files, which are imported by other libraries, but are a small library cycle that does not import much outside of it. Change-Id: I904c05d6d5b444ee9a9dbd1f7ada12aabdcc5165 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/193583 Reviewed-by: Brian Wilkerson <[email protected]> Commit-Queue: Konstantin Shcheglov <[email protected]>
1 parent b7d6149 commit e97f1bd

File tree

1,198 files changed

+2412
-2
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,198 files changed

+2412
-2
lines changed

.dart_tool/package_config.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@
7070
"name": "analysis_server",
7171
"rootUri": "../pkg/analysis_server",
7272
"packageUri": "lib/",
73-
"languageVersion": "2.6"
73+
"languageVersion": "2.12"
7474
},
7575
{
7676
"name": "analysis_server_client",

pkg/analysis_server/benchmark/benchmarks.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:convert';
68
import 'dart:io';
79
import 'dart:math' as math;

pkg/analysis_server/benchmark/integration/driver.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:async';
68
import 'dart:math' show max, sqrt;
79

pkg/analysis_server/benchmark/integration/input_converter.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:async';
68
import 'dart:convert';
79
import 'dart:io';

pkg/analysis_server/benchmark/integration/instrumentation_input_converter.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:convert';
68

79
import 'package:analyzer/exception/exception.dart';

pkg/analysis_server/benchmark/integration/local_runner.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:io';
68

79
import 'package:path/path.dart';

pkg/analysis_server/benchmark/integration/log_file_input_converter.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:convert';
68

79
import 'package:analyzer/exception/exception.dart';

pkg/analysis_server/benchmark/integration/main.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:async';
68
import 'dart:convert';
79
import 'dart:io';

pkg/analysis_server/benchmark/integration/operation.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:async';
68

79
import 'package:analysis_server/protocol/protocol_generated.dart';

pkg/analysis_server/benchmark/perf/benchmarks_impl.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:async';
68
import 'dart:io';
79

pkg/analysis_server/benchmark/perf/flutter_analyze_benchmark.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:convert';
68
import 'dart:io';
79

pkg/analysis_server/benchmark/perf/memory_tests.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:async';
68
import 'dart:convert' show jsonDecode, jsonEncode;
79
import 'dart:io';

pkg/analysis_server/bin/server.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analysis_server/starter.dart';
68

79
/// Create and run an analysis server.

pkg/analysis_server/lib/lsp_protocol/protocol_custom_generated.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
// This file has been automatically generated. Please do not edit it manually.
68
// To regenerate the file, use the script
79
// "pkg/analysis_server/tool/lsp_spec/generate_all.dart".

pkg/analysis_server/lib/lsp_protocol/protocol_generated.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
// This file has been automatically generated. Please do not edit it manually.
68
// To regenerate the file, use the script
79
// "pkg/analysis_server/tool/lsp_spec/generate_all.dart".

pkg/analysis_server/lib/lsp_protocol/protocol_special.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:async';
68

79
import 'package:analysis_server/lsp_protocol/protocol_generated.dart';

pkg/analysis_server/lib/plugin/analysis/occurrences/occurrences_core.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analyzer_plugin/protocol/protocol_common.dart' show Occurrences;
68

79
/// An object used to record occurrences into.

pkg/analysis_server/lib/plugin/edit/assist/assist_core.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analyzer_plugin/protocol/protocol_common.dart'
68
show SourceChange;
79
import 'package:analyzer_plugin/utilities/assist/assist.dart';

pkg/analysis_server/lib/plugin/edit/assist/assist_dart.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analyzer/dart/analysis/results.dart';
68
import 'package:analyzer/instrumentation/service.dart';
79
import 'package:analyzer_plugin/utilities/change_builder/change_workspace.dart';

pkg/analysis_server/lib/plugin/edit/fix/fix_core.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analyzer/error/error.dart';
68
import 'package:analyzer_plugin/protocol/protocol_common.dart'
79
show SourceChange;

pkg/analysis_server/lib/plugin/edit/fix/fix_dart.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analysis_server/plugin/edit/fix/fix_core.dart';
68
import 'package:analysis_server/src/services/correction/fix/dart/top_level_declarations.dart';
79
import 'package:analyzer/dart/analysis/results.dart';

pkg/analysis_server/lib/plugin/protocol/protocol_dart.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
/// Utilities for converting Dart entities into analysis server's protocol
68
/// entities.
79
import 'package:analysis_server/src/protocol_server.dart';

pkg/analysis_server/lib/protocol/protocol.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
/// Support for client code that needs to interact with the requests, responses
68
/// and notifications that are part of the analysis server's wire protocol.
79
import 'dart:convert' hide JsonDecoder;

pkg/analysis_server/lib/protocol/protocol_constants.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66
// To regenerate the file, use the script
77
// "pkg/analysis_server/tool/spec/generate_files".
88

9+
// @dart = 2.9
10+
911
const String PROTOCOL_VERSION = '1.32.5';
1012

1113
const String ANALYSIS_NOTIFICATION_ANALYZED_FILES = 'analysis.analyzedFiles';

pkg/analysis_server/lib/protocol/protocol_generated.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66
// To regenerate the file, use the script
77
// "pkg/analysis_server/tool/spec/generate_files".
88

9+
// @dart = 2.9
10+
911
import 'dart:convert' hide JsonDecoder;
1012

1113
import 'package:analyzer/src/generated/utilities_general.dart';

pkg/analysis_server/lib/src/analysis_server.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:async';
68
import 'dart:collection';
79
import 'dart:core';

pkg/analysis_server/lib/src/analysis_server_abstract.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:core';
68
import 'dart:io' as io;
79
import 'dart:io';

pkg/analysis_server/lib/src/channel/byte_stream_channel.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:async';
68
import 'dart:convert';
79
import 'dart:io';

pkg/analysis_server/lib/src/channel/channel.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:convert';
68

79
import 'package:analysis_server/protocol/protocol.dart';

pkg/analysis_server/lib/src/cider/assists.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analysis_server/plugin/edit/assist/assist_core.dart';
68
import 'package:analysis_server/src/services/correction/assist.dart';
79
import 'package:analysis_server/src/services/correction/assist_internal.dart';

pkg/analysis_server/lib/src/cider/completion.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analysis_server/src/protocol_server.dart';
68
import 'package:analysis_server/src/services/completion/completion_core.dart';
79
import 'package:analysis_server/src/services/completion/completion_performance.dart';

pkg/analysis_server/lib/src/cider/fixes.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analysis_server/plugin/edit/fix/fix_core.dart';
68
import 'package:analysis_server/src/services/correction/change_workspace.dart';
79
import 'package:analysis_server/src/services/correction/fix.dart';

pkg/analysis_server/lib/src/collections.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
/// Returns the given [list] if it is not empty, or `null` otherwise.
68
List<E> nullIfEmpty<E>(List<E> list) {
79
if (list == null) {

pkg/analysis_server/lib/src/computer/computer_closingLabels.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analysis_server/protocol/protocol_generated.dart';
68
import 'package:analyzer/dart/ast/ast.dart';
79
import 'package:analyzer/dart/ast/visitor.dart';

pkg/analysis_server/lib/src/computer/computer_folding.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analyzer/dart/ast/ast.dart';
68
import 'package:analyzer/dart/ast/token.dart';
79
import 'package:analyzer/dart/ast/visitor.dart';

pkg/analysis_server/lib/src/computer/computer_highlights.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analysis_server/lsp_protocol/protocol_generated.dart'
68
show SemanticTokenTypes, SemanticTokenModifiers;
79
import 'package:analysis_server/src/lsp/constants.dart'

pkg/analysis_server/lib/src/computer/computer_hover.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analysis_server/protocol/protocol_generated.dart'
68
show HoverInformation;
79
import 'package:analysis_server/src/computer/computer_overrides.dart';

pkg/analysis_server/lib/src/computer/computer_outline.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analysis_server/src/collections.dart';
68
import 'package:analysis_server/src/utilities/flutter.dart';
79
import 'package:analyzer/dart/analysis/results.dart';

pkg/analysis_server/lib/src/computer/computer_overrides.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analysis_server/src/collections.dart';
68
import 'package:analysis_server/src/protocol_server.dart' as proto;
79
import 'package:analyzer/dart/ast/ast.dart';

pkg/analysis_server/lib/src/computer/computer_signature.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analysis_server/src/computer/computer_hover.dart';
68
import 'package:analysis_server/src/protocol_server.dart';
79
import 'package:analyzer/dart/ast/ast.dart';

pkg/analysis_server/lib/src/computer/import_elements_computer.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analysis_server/protocol/protocol_generated.dart';
68
import 'package:analyzer/dart/analysis/results.dart';
79
import 'package:analyzer/dart/ast/ast.dart';

pkg/analysis_server/lib/src/computer/imported_elements_computer.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'package:analysis_server/protocol/protocol_generated.dart';
68
import 'package:analyzer/dart/ast/ast.dart';
79
import 'package:analyzer/dart/ast/visitor.dart';

pkg/analysis_server/lib/src/context_manager.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:async';
68
import 'dart:collection';
79
import 'dart:core';

pkg/analysis_server/lib/src/domain_abstract.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5+
// @dart = 2.9
6+
57
import 'dart:async';
68
import 'dart:convert';
79
import 'dart:math' as math;

0 commit comments

Comments
 (0)