Skip to content

Commit a75ffc8

Browse files
sigmundchcommit-bot@chromium.org
authored andcommitted
Add non-NNBD language version marker to all sdk (non-nnbd) files
This is practically a copy of the change in https://dart-review.googlesource.com/c/sdk/+/118040 but applied to the non-nnbd sdk. Even though there is no intent to run the non-nnbd sdk with the non-nullable experiment, we need to add this annotation because of how we intend to gradually start testing NNBD. The libraries.json under sdk_nnbd is allowed to point to libraries under the non-nnbd sdk in order to temporarily build without errors until all patch files are migrated and all CFE issues are addressed. Change-Id: I53c1123a8d86c10695832a8a0ad35adb7b4d92fd Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/125181 Commit-Queue: Sigmund Cherem <[email protected]> Reviewed-by: Bob Nystrom <[email protected]>
1 parent ebd9af9 commit a75ffc8

File tree

344 files changed

+695
-17
lines changed

Some content is hidden

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

344 files changed

+695
-17
lines changed

pkg/front_end/lib/src/fasta/source/source_library_builder.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ import 'source_loader.dart' show SourceLoader;
214214

215215
// TODO(johnniwinther,jensj): Replace this with the correct scheme.
216216
const int enableNonNullableDefaultMajorVersion = 2;
217-
const int enableNonNullableDefaultMinorVersion = 6;
217+
const int enableNonNullableDefaultMinorVersion = 7;
218218

219219
class SourceLibraryBuilder extends LibraryBuilderImpl {
220220
static const String MALFORMED_URI_SCHEME = "org-dartlang-malformed-uri";

pkg/front_end/testcases/general/sdk_diagnostic.dart.outline.expect

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ library;
1212
//
1313
// class C extends Iterable<Object> {
1414
// ^
15-
// sdk/lib/core/iterable.dart:154:19: Context: 'Iterable.iterator' is defined here.
15+
// sdk/lib/core/iterable.dart:156:19: Context: 'Iterable.iterator' is defined here.
1616
// Iterator<E> get iterator;
1717
// ^^^^^^^^
1818
//

pkg/front_end/testcases/general/sdk_diagnostic.dart.strong.expect

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,14 @@ library;
1212
//
1313
// class C extends Iterable<Object> {
1414
// ^
15-
// sdk/lib/core/iterable.dart:154:19: Context: 'Iterable.iterator' is defined here.
15+
// sdk/lib/core/iterable.dart:156:19: Context: 'Iterable.iterator' is defined here.
1616
// Iterator<E> get iterator;
1717
// ^^^^^^^^
1818
//
1919
// pkg/front_end/testcases/general/sdk_diagnostic.dart:12:8: Error: Too few positional arguments: 1 required, 0 given.
2020
// print(incorrectArgument: "fisk");
2121
// ^
22-
// sdk/lib/core/print.dart:8:6: Context: Found this candidate, but the arguments don't match.
22+
// sdk/lib/core/print.dart:10:6: Context: Found this candidate, but the arguments don't match.
2323
// void print(Object object) {
2424
// ^^^^^
2525
//

pkg/front_end/testcases/general/sdk_diagnostic.dart.strong.transformed.expect

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,14 @@ library;
1212
//
1313
// class C extends Iterable<Object> {
1414
// ^
15-
// sdk/lib/core/iterable.dart:154:19: Context: 'Iterable.iterator' is defined here.
15+
// sdk/lib/core/iterable.dart:156:19: Context: 'Iterable.iterator' is defined here.
1616
// Iterator<E> get iterator;
1717
// ^^^^^^^^
1818
//
1919
// pkg/front_end/testcases/general/sdk_diagnostic.dart:12:8: Error: Too few positional arguments: 1 required, 0 given.
2020
// print(incorrectArgument: "fisk");
2121
// ^
22-
// sdk/lib/core/print.dart:8:6: Context: Found this candidate, but the arguments don't match.
22+
// sdk/lib/core/print.dart:10:6: Context: Found this candidate, but the arguments don't match.
2323
// void print(Object object) {
2424
// ^^^^^
2525
//

runtime/bin/vmservice/loader.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.6
6+
57
part of vmservice_io;
68

79
_sanitizeWindowsPath(path) {

runtime/bin/vmservice/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.6
6+
57
part of vmservice_io;
68

79
final bool silentObservatory = new bool.fromEnvironment('SILENT_OBSERVATORY');

runtime/bin/vmservice/vmservice_io.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.6
6+
57
library vmservice_io;
68

79
import 'dart:async';

runtime/observatory/tests/service/step_through_mixin_from_sdk_test.dart

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -35,19 +35,19 @@ List<String> stops = [];
3535
List<String> expected = [
3636
"$file:${LINE + 0}:17", // on "Foo" (in "new Foo()")
3737
"$file:${LINE + 1}:11", // on "="
38-
"list.dart:105:24", // on parameter to "contains"
39-
"list.dart:106:23", // on "length" in "this.length"
40-
"list.dart:107:16", // on "=" in "i = 0"
41-
"list.dart:107:23", // on "<" in "i < length"
42-
"list.dart:108:15", // on "[" in "this[i]"
38+
"list.dart:107:24", // on parameter to "contains"
39+
"list.dart:108:23", // on "length" in "this.length"
40+
"list.dart:109:16", // on "=" in "i = 0"
41+
"list.dart:109:23", // on "<" in "i < length"
42+
"list.dart:110:15", // on "[" in "this[i]"
4343
"$file:${LINE + 13}:23", // on parameter in "operator []"
4444
"$file:${LINE + 14}:5", // on "return"
45-
"list.dart:108:19", // on "=="
46-
"list.dart:109:26", // on "length" in "this.length"
47-
"list.dart:109:18", // on "!="
48-
"list.dart:107:34", // on "++" in "i++"
49-
"list.dart:107:23", // on "<" in "i < length"
50-
"list.dart:113:5", // on "return"
45+
"list.dart:110:19", // on "=="
46+
"list.dart:111:26", // on "length" in "this.length"
47+
"list.dart:111:18", // on "!="
48+
"list.dart:109:34", // on "++" in "i++"
49+
"list.dart:109:23", // on "<" in "i < length"
50+
"list.dart:115:5", // on "return"
5151
"$file:${LINE + 4}:5", // on "print"
5252
"$file:${LINE + 6}:1" // on ending '}'
5353
];

sdk/lib/_http/crypto.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.6
6+
57
part of dart._http;
68

79
class _CryptoUtils {

sdk/lib/_http/http.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.6
6+
57
library dart._http;
68

79
import 'dart:async';

sdk/lib/_http/http_date.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.6
6+
57
part of dart._http;
68

79
/**

sdk/lib/_http/http_headers.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.6
6+
57
part of dart._http;
68

79
class _HttpHeaders implements HttpHeaders {

sdk/lib/_http/http_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.6
6+
57
part of dart._http;
68

79
int _nextServiceId = 1;

sdk/lib/_http/http_parser.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.6
6+
57
part of dart._http;
68

79
// Global constants.

sdk/lib/_http/http_session.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.6
6+
57
part of dart._http;
68

79
const String _DART_SESSION_ID = "DARTSESSID";

sdk/lib/_http/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.6
6+
57
part of dart._http;
68

79
final _httpOverridesToken = new Object();

sdk/lib/_http/websocket.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.6
6+
57
part of dart._http;
68

79
/**

sdk/lib/_http/websocket_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.6
6+
57
part of dart._http;
68

79
const String _webSocketGUID = "258EAFA5-E914-47DA-95CA-C5AB0DC85B11";

sdk/lib/_internal/js_dev_runtime/lib/js/dart2js/js_dart2js.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.6
6+
57
// DDC version of sdk/lib/js/dart2js/js_dart2js.dart
68

79
/// Low-level support for interoperating with JavaScript.

sdk/lib/_internal/js_dev_runtime/lib/js_util/dart2js/js_util_dart2js.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.6
6+
57
/// Utility methods to efficiently manipulate typed JSInterop objects in cases
68
/// where the name to call is not known at runtime. You should only use these
79
/// methods when the same effect cannot be achieved with @JS annotations.

sdk/lib/_internal/js_dev_runtime/libraries.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.6
6+
57
library libraries;
68

79
/**

sdk/lib/_internal/js_dev_runtime/patch/async_patch.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.6
6+
57
// Patch file for the dart:async library.
68

79
import 'dart:_js_helper' show notNull, patch, ReifyFunctionTypes;

sdk/lib/_internal/js_dev_runtime/patch/cli_patch.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.6
6+
57
import 'dart:_js_helper' show patch;
68

79
@patch

sdk/lib/_internal/js_dev_runtime/patch/collection_patch.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.6
6+
57
// Patch file for dart:collection classes.
68
import 'dart:_foreign_helper' show JS, JSExportName;
79
import 'dart:_runtime' as dart;

sdk/lib/_internal/js_dev_runtime/patch/convert_patch.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.6
6+
57
// Patch file for dart:convert library.
68

79
import 'dart:_js_helper' show argumentErrorValue, patch;

sdk/lib/_internal/js_dev_runtime/patch/core_patch.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.6
6+
57
// Patch file for dart:core classes.
68
import "dart:_internal" as _symbol_dev;
79
import 'dart:_interceptors';

sdk/lib/_internal/js_dev_runtime/patch/developer_patch.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.6
6+
57
// Patch file for dart:developer library.
68

79
import 'dart:_js_helper' show patch, ForceInline, ReifyFunctionTypes;

sdk/lib/_internal/js_dev_runtime/patch/internal_patch.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.6
6+
57
import 'dart:core' hide Symbol;
68
import 'dart:core' as core show Symbol;
79
import 'dart:_js_primitives' show printString;

sdk/lib/_internal/js_dev_runtime/patch/io_patch.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.6
6+
57
import 'dart:_js_helper' show patch;
68
import 'dart:async';
79
import 'dart:convert';

sdk/lib/_internal/js_dev_runtime/patch/isolate_patch.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.6
6+
57
// Patch file for the dart:isolate library.
68

79
import 'dart:_js_helper' show patch, NoReifyGeneric;

sdk/lib/_internal/js_dev_runtime/patch/math_patch.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.6
6+
57
// Patch file for dart:math library.
68
import 'dart:_foreign_helper' show JS;
79
import 'dart:_js_helper' show patch, nullCheck, notNull;

sdk/lib/_internal/js_dev_runtime/patch/mirrors_patch.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.6
6+
57
// Patch library for dart:mirrors.
68

79
import 'dart:_js_helper' show patch;

sdk/lib/_internal/js_dev_runtime/patch/typed_data_patch.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.6
6+
57
import 'dart:collection';
68
import 'dart:_js_helper' show patch;
79
import 'dart:_native_typed_data';

sdk/lib/_internal/js_dev_runtime/private/annotations.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.6
6+
57
part of dart._js_helper;
68

79
/// Tells the optimizing compiler to always inline the annotated method.

sdk/lib/_internal/js_dev_runtime/private/custom_hash_map.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.6
6+
57
part of dart._js_helper;
68

79
class CustomKeyHashMap<K, V> extends CustomHashMap<K, V> {

sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/classes.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.6
6+
57
/// This library defines the operations that define and manipulate Dart
68
/// classes. Included in this are:
79
/// - Generics

sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/errors.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.6
6+
57
part of dart._runtime;
68

79
// We need to set these properties while the sdk is only partially initialized

sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/operations.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.6
6+
57
/// This library defines runtime operations on objects used by the code
68
/// generator.
79
part of dart._runtime;

sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/rtti.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.6
6+
57
/// This library defines the association between runtime objects and
68
/// runtime types.
79
part of dart._runtime;

sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/runtime.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.6
6+
57
@ReifyFunctionTypes(false)
68
library dart._runtime;
79

0 commit comments

Comments
 (0)