Version 2.17.0-278.0.dev
Merge commit '560579b584f1f9b97109689deb6b723d77edcf0b' into 'dev'
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 7cfff32..6284408 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,12 @@
+## 2.18.0
+
+### Core libraries
+
+#### `dart:html`
+
+- Add `connectionState` attribute and `connectionstatechange` listener to
+ `RtcPeerConnection`.
+
## 2.17.0
### Core libraries
diff --git a/pkg/analyzer/lib/src/dart/analysis/search.dart b/pkg/analyzer/lib/src/dart/analysis/search.dart
index f6af5ab..477404f 100644
--- a/pkg/analyzer/lib/src/dart/analysis/search.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/search.dart
@@ -167,125 +167,9 @@
Future<void> declarations(
WorkspaceSymbols result, RegExp? regExp, int? maxResults,
{String? onlyForFile, CancellationToken? cancellationToken}) async {
- if (result.hasMoreDeclarationsThan(maxResults)) {
- return;
- }
-
- void addDeclaration(LineInfo lineInfo, Element element) {
- if (result.hasMoreDeclarationsThan(maxResults)) {
- throw const _MaxNumberOfDeclarationsError();
- }
-
- if (element.isSynthetic) {
- return;
- }
-
- var source = element.source;
- if (source == null) {
- return;
- }
-
- var path = source.fullName;
- if (onlyForFile != null && path != onlyForFile) {
- return;
- }
-
- var name = element.name;
- if (name == null || name.isEmpty) {
- return;
- }
- if (name.endsWith('=')) {
- name = name.substring(0, name.length - 1);
- }
- if (regExp != null && !regExp.hasMatch(name)) {
- return;
- }
-
- var enclosing = element.enclosingElement;
-
- String? className;
- String? mixinName;
- if (enclosing is ClassElement) {
- if (enclosing.isEnum) {
- // skip
- } else if (enclosing.isMixin) {
- mixinName = enclosing.name;
- } else {
- className = enclosing.name;
- }
- }
-
- var kind = _getSearchElementKind(element);
- if (kind == null) {
- return;
- }
-
- String? parameters;
- if (element is ExecutableElement) {
- var displayString = element.getDisplayString(withNullability: true);
- var parameterIndex = displayString.indexOf('(');
- if (parameterIndex > 0) {
- parameters = displayString.substring(parameterIndex);
- }
- }
-
- element as ElementImpl; // to access codeOffset/codeLength
- var locationOffset = element.nameOffset;
- var locationStart = lineInfo.getLocation(locationOffset);
-
- result.declarations.add(
- Declaration(
- result._getPathIndex(path),
- lineInfo,
- name,
- kind,
- locationOffset,
- locationStart.lineNumber,
- locationStart.columnNumber,
- element.codeOffset ?? 0,
- element.codeLength ?? 0,
- className,
- mixinName,
- parameters,
- ),
- );
- }
-
- await _driver.discoverAvailableFiles();
-
- if (cancellationToken?.isCancellationRequested ?? false) {
- result.cancelled = true;
- return;
- }
-
- var knownFiles = _driver.fsState.knownFiles.toList();
- var filesProcessed = 0;
- for (var file in knownFiles) {
- var libraryElement = _driver.getLibraryByFile(file);
- if (libraryElement != null) {
- for (var unitElement in libraryElement.units) {
- try {
- unitElement.accept(
- _FunctionElementVisitor((element) {
- addDeclaration(unitElement.lineInfo, element);
- }),
- );
- } on _MaxNumberOfDeclarationsError {
- return;
- }
- }
- }
- filesProcessed++;
-
- // Periodically yield and check cancellation token.
- if (cancellationToken != null && filesProcessed % 20 == 0) {
- await null; // allow cancellation requests to be processed.
- if (cancellationToken.isCancellationRequested) {
- result.cancelled = true;
- return;
- }
- }
- }
+ await _FindDeclarations(_driver, result, regExp, maxResults,
+ onlyForFile: onlyForFile)
+ .compute(cancellationToken);
}
/// Returns references to the [element].
@@ -876,16 +760,209 @@
}
}
-/// A visitor that handles any element with a function.
-class _FunctionElementVisitor extends GeneralizingElementVisitor<void> {
- final void Function(Element element) process;
+class _FindDeclarations {
+ final AnalysisDriver driver;
+ final WorkspaceSymbols result;
+ final int? maxResults;
+ final RegExp? regExp;
+ final String? onlyForFile;
- _FunctionElementVisitor(this.process);
+ _FindDeclarations(this.driver, this.result, this.regExp, this.maxResults,
+ {this.onlyForFile});
- @override
- void visitElement(Element element) {
- process(element);
- super.visitElement(element);
+ /// Add matching declarations to the [result].
+ Future<void> compute(CancellationToken? cancellationToken) async {
+ if (result.hasMoreDeclarationsThan(maxResults)) {
+ return;
+ }
+
+ await driver.discoverAvailableFiles();
+
+ if (cancellationToken != null &&
+ cancellationToken.isCancellationRequested) {
+ result.cancelled = true;
+ return;
+ }
+
+ var knownFiles = driver.fsState.knownFiles.toList();
+ var filesProcessed = 0;
+ try {
+ for (var file in knownFiles) {
+ var libraryElement = driver.getLibraryByFile(file);
+ if (libraryElement != null) {
+ _addUnits(file, libraryElement.units);
+ }
+
+ // Periodically yield and check cancellation token.
+ if (cancellationToken != null && (filesProcessed++) % 20 == 0) {
+ await null; // allow cancellation requests to be processed.
+ if (cancellationToken.isCancellationRequested) {
+ result.cancelled = true;
+ return;
+ }
+ }
+ }
+ } on _MaxNumberOfDeclarationsError {
+ return;
+ }
+ }
+
+ void _addAccessors(FileState file, List<PropertyAccessorElement> elements) {
+ for (var i = 0; i < elements.length; i++) {
+ var element = elements[i];
+ if (!element.isSynthetic) {
+ _addDeclaration(file, element, element.displayName);
+ }
+ }
+ }
+
+ void _addClasses(FileState file, List<ClassElement> elements) {
+ for (var i = 0; i < elements.length; i++) {
+ var element = elements[i];
+ _addDeclaration(file, element, element.name);
+ _addAccessors(file, element.accessors);
+ _addConstructors(file, element.constructors);
+ _addFields(file, element.fields);
+ _addMethods(file, element.methods);
+ }
+ }
+
+ void _addConstructors(FileState file, List<ConstructorElement> elements) {
+ for (var i = 0; i < elements.length; i++) {
+ var element = elements[i];
+ if (!element.isSynthetic) {
+ _addDeclaration(file, element, element.name);
+ }
+ }
+ }
+
+ void _addDeclaration(FileState file, Element element, String name) {
+ if (result.hasMoreDeclarationsThan(maxResults)) {
+ throw const _MaxNumberOfDeclarationsError();
+ }
+
+ if (onlyForFile != null && file.path != onlyForFile) {
+ return;
+ }
+
+ if (regExp != null && !regExp!.hasMatch(name)) {
+ return;
+ }
+
+ var enclosing = element.enclosingElement;
+
+ String? className;
+ String? mixinName;
+ if (enclosing is ClassElement) {
+ if (enclosing.isEnum) {
+ // skip
+ } else if (enclosing.isMixin) {
+ mixinName = enclosing.name;
+ } else {
+ className = enclosing.name;
+ }
+ }
+
+ var kind = _getSearchElementKind(element);
+ if (kind == null) {
+ return;
+ }
+
+ String? parameters;
+ if (element is ExecutableElement) {
+ var displayString = element.getDisplayString(withNullability: true);
+ var parameterIndex = displayString.indexOf('(');
+ if (parameterIndex > 0) {
+ parameters = displayString.substring(parameterIndex);
+ }
+ }
+
+ element as ElementImpl; // to access codeOffset/codeLength
+ var locationOffset = element.nameOffset;
+ var locationStart = file.lineInfo.getLocation(locationOffset);
+
+ result.declarations.add(
+ Declaration(
+ result._getPathIndex(file.path),
+ file.lineInfo,
+ name,
+ kind,
+ locationOffset,
+ locationStart.lineNumber,
+ locationStart.columnNumber,
+ element.codeOffset ?? 0,
+ element.codeLength ?? 0,
+ className,
+ mixinName,
+ parameters,
+ ),
+ );
+ }
+
+ void _addExtensions(FileState file, List<ExtensionElement> elements) {
+ for (var i = 0; i < elements.length; i++) {
+ var element = elements[i];
+ var name = element.name;
+ if (name != null) {
+ _addDeclaration(file, element, name);
+ }
+ _addAccessors(file, element.accessors);
+ _addFields(file, element.fields);
+ _addMethods(file, element.methods);
+ }
+ }
+
+ void _addFields(FileState file, List<FieldElement> elements) {
+ for (var i = 0; i < elements.length; i++) {
+ var element = elements[i];
+ if (!element.isSynthetic) {
+ _addDeclaration(file, element, element.name);
+ }
+ }
+ }
+
+ void _addFunctions(FileState file, List<FunctionElement> elements) {
+ for (var i = 0; i < elements.length; i++) {
+ var element = elements[i];
+ _addDeclaration(file, element, element.name);
+ }
+ }
+
+ void _addMethods(FileState file, List<MethodElement> elements) {
+ for (var i = 0; i < elements.length; i++) {
+ var element = elements[i];
+ _addDeclaration(file, element, element.name);
+ }
+ }
+
+ void _addTypeAliases(FileState file, List<TypeAliasElement> elements) {
+ for (var i = 0; i < elements.length; i++) {
+ var element = elements[i];
+ _addDeclaration(file, element, element.name);
+ }
+ }
+
+ void _addUnits(FileState file, List<CompilationUnitElement> elements) {
+ for (var i = 0; i < elements.length; i++) {
+ var element = elements[i];
+ _addAccessors(file, element.accessors);
+ _addClasses(file, element.classes);
+ _addClasses(file, element.enums);
+ _addClasses(file, element.mixins);
+ _addExtensions(file, element.extensions);
+ _addFunctions(file, element.functions);
+ _addTypeAliases(file, element.typeAliases);
+ _addVariables(file, element.topLevelVariables);
+ }
+ }
+
+ void _addVariables(FileState file, List<TopLevelVariableElement> elements) {
+ for (var i = 0; i < elements.length; i++) {
+ var element = elements[i];
+ if (!element.isSynthetic) {
+ _addDeclaration(file, element, element.name);
+ }
+ }
}
}
diff --git a/pkg/analyzer/test/src/dart/analysis/search_test.dart b/pkg/analyzer/test/src/dart/analysis/search_test.dart
index 234a6ec..fc3afd1 100644
--- a/pkg/analyzer/test/src/dart/analysis/search_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/search_test.dart
@@ -237,6 +237,30 @@
offset: 18, codeOffset: 18, codeLength: 3);
}
+ test_declarations_extension() async {
+ await resolveTestCode('''
+extension E on int {
+ int f;
+ int get g => 0;
+ void set s(_) {}
+ void m() {}
+}
+''');
+ var results = WorkspaceSymbols();
+ await driver.search.declarations(results, null, null);
+ var declarations = results.declarations;
+ declarations.assertHas('E', DeclarationKind.EXTENSION,
+ offset: 10, codeOffset: 0, codeLength: 82);
+ declarations.assertHas('f', DeclarationKind.FIELD,
+ offset: 27, codeOffset: 23, codeLength: 5);
+ declarations.assertHas('g', DeclarationKind.GETTER,
+ offset: 40, codeOffset: 32, codeLength: 15);
+ declarations.assertHas('s', DeclarationKind.SETTER,
+ offset: 59, codeOffset: 50, codeLength: 16);
+ declarations.assertHas('m', DeclarationKind.METHOD,
+ offset: 74, codeOffset: 69, codeLength: 11);
+ }
+
test_declarations_maxResults() async {
await resolveTestCode('''
class A {}
diff --git a/pkg/analyzer/test/src/dart/analysis/unlinked_api_signature_test.dart b/pkg/analyzer/test/src/dart/analysis/unlinked_api_signature_test.dart
index 954761a..64302a5 100644
--- a/pkg/analyzer/test/src/dart/analysis/unlinked_api_signature_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/unlinked_api_signature_test.dart
@@ -16,34 +16,8 @@
@reflectiveTest
class UnitApiSignatureTest extends ParseBase {
- void assertNotSameSignature(String oldCode, String newCode) {
- assertSignature(oldCode, newCode, same: false);
- }
-
- void assertSameSignature(String oldCode, String newCode) {
- assertSignature(oldCode, newCode, same: true);
- }
-
- void assertSignature(String oldCode, String newCode, {required bool same}) {
- var path = convertPath('/test.dart');
-
- newFile2(path, oldCode);
- var oldUnit = parseUnit(path).unit;
- var oldSignature = computeUnlinkedApiSignature(oldUnit);
-
- newFile2(path, newCode);
- var newUnit = parseUnit(path).unit;
- var newSignature = computeUnlinkedApiSignature(newUnit);
-
- if (same) {
- expect(newSignature, oldSignature);
- } else {
- expect(newSignature, isNot(oldSignature));
- }
- }
-
test_class_annotation() async {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
const a = 0;
class C {}
@@ -56,7 +30,7 @@
}
test_class_constructor_block_to_empty() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
class C {
C() {
var v = 1;
@@ -70,7 +44,7 @@
}
test_class_constructor_body() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
class C {
C() {
var v = 1;
@@ -86,7 +60,7 @@
}
test_class_constructor_empty_to_block() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
class C {
C();
}
@@ -100,7 +74,7 @@
}
test_class_constructor_initializer_const() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class C {
final int f;
const C() : f = 1;
@@ -114,7 +88,7 @@
}
test_class_constructor_initializer_empty() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class C {
C.foo() : ;
}
@@ -127,7 +101,7 @@
/// See https://github.com/dart-lang/sdk/issues/46206
test_class_constructor_initializer_notConst() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class C {
final int f;
C.foo() : f = 1;
@@ -143,7 +117,7 @@
}
test_class_constructor_parameters_add() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class C {
C(int a);
}
@@ -155,7 +129,7 @@
}
test_class_constructor_parameters_remove() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class C {
C(int a, int b);
}
@@ -167,7 +141,7 @@
}
test_class_constructor_parameters_rename() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class C {
C(int a);
}
@@ -179,7 +153,7 @@
}
test_class_constructor_parameters_type() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class C {
C(int p);
}
@@ -191,7 +165,7 @@
}
test_class_constructor_redirectedConstructor_const() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class A {
const factory A() = B.foo;
}
@@ -211,7 +185,7 @@
}
test_class_constructor_redirectedConstructor_notConst() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class A {
factory A() = B.foo;
}
@@ -231,7 +205,7 @@
}
test_class_documentation_add() async {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
class C {}
''', r'''
/// foo
@@ -240,7 +214,7 @@
}
test_class_documentation_change() async {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
/// foo
class C {}
''', r'''
@@ -250,7 +224,7 @@
}
test_class_documentation_remove() async {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
/// foo
class C {}
''', r'''
@@ -259,7 +233,7 @@
}
test_class_extends() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class A {}
class B {}
''', r'''
@@ -273,7 +247,7 @@
/// byte sequence as the empty string. But these are different ASTs,
/// so they should have different signatures.
test_class_factoryConstructor_addEqNothing() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class A {
factory A();
}
@@ -290,7 +264,7 @@
/// at the same position, without any separator, so failed to see the
/// difference.
test_class_factoryConstructor_empty_to_eq() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class A {
factory A();
static void foo<U>() {}
@@ -304,7 +278,7 @@
}
test_class_field_const_add_outOfOrder() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class A {
static f = Object();
}
@@ -316,117 +290,8 @@
''');
}
- test_class_field_const_add_outOfOrder_hasFinal() {
- assertNotSameSignature(r'''
-class A {
- static final f = Object();
-}
-''', r'''
-class A {
- const
- static final f = Object();
-}
-''');
- }
-
- test_class_field_final_add() {
- assertNotSameSignature(r'''
-class C {
- int a = 0;
-}
-''', r'''
-class C {
- final int a = 0;
-}
-''');
- }
-
- test_class_field_late_add() {
- assertNotSameSignature(r'''
-class C {
- int a;
-}
-''', r'''
-class C {
- late int a;
-}
-''');
- }
-
- test_class_field_late_remove() {
- assertNotSameSignature(r'''
-class C {
- late int a;
-}
-''', r'''
-class C {
- int a;
-}
-''');
- }
-
- test_class_field_static_add() {
- assertNotSameSignature(r'''
-class C {
- int a;
-}
-''', r'''
-class C {
- static int a;
-}
-''');
- }
-
- test_class_field_withoutType() {
- assertNotSameSignature(r'''
-class C {
- var a = 1;
-}
-''', r'''
-class C {
- var a = 2;
-}
-''');
- }
-
- test_class_field_withoutType2() {
- assertNotSameSignature(r'''
-class C {
- var a = 1, b = 2, c, d = 4;
-}
-''', r'''
-class C {
- var a = 1, b, c = 3, d = 4;
-}
-''');
- }
-
- test_class_field_withType() {
- assertSameSignature(r'''
-class C {
- int a = 1;
-}
-''', r'''
-class C {
- int a = 2;
-}
-''');
- }
-
- test_class_field_withType_const() {
- assertNotSameSignature(r'''
-class C {
- static const int a = 1;
-}
-''', r'''
-class C {
- static const int a = 2;
-}
-''');
- }
-
test_class_field_withType_final_hasConstConstructor() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class C {
final int a = 1;
const C();
@@ -439,20 +304,8 @@
''');
}
- test_class_field_withType_final_noConstConstructor() {
- assertSameSignature(r'''
-class C {
- final int a = 1;
-}
-''', r'''
-class C {
- final int a = 2;
-}
-''');
- }
-
test_class_field_withType_hasConstConstructor() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
class C {
int a = 1;
const C();
@@ -466,7 +319,7 @@
}
test_class_field_withType_static_final_hasConstConstructor() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
class C {
static final int a = 1;
const C();
@@ -480,7 +333,7 @@
}
test_class_field_withType_static_hasConstConstructor() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
class C {
static int a = 1;
const C();
@@ -494,7 +347,7 @@
}
test_class_implements() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class A {}
class B {}
''', r'''
@@ -503,401 +356,8 @@
''');
}
- test_class_method_annotation() {
- assertNotSameSignature(r'''
-const a = 0;
-
-class C {
- void foo() {}
-}
-''', r'''
-const a = 0;
-
-class C {
- @a
- void foo() {}
-}
-''');
- }
-
- test_class_method_body_async_to_asyncStar() {
- assertNotSameSignature(r'''
-class C {
- foo() async {}
-}
-''', r'''
-class C {
- foo() async* {}
-}
-''');
- }
-
- test_class_method_body_async_to_sync() {
- assertNotSameSignature(r'''
-class C {
- foo() async {}
-}
-''', r'''
-class C {
- foo() {}
-}
-''');
- }
-
- test_class_method_body_asyncStar_to_async() {
- assertNotSameSignature(r'''
-class C {
- foo() async* {}
-}
-''', r'''
-class C {
- foo() async {}
-}
-''');
- }
-
- test_class_method_body_asyncStar_to_syncStar() {
- assertNotSameSignature(r'''
-class C {
- foo() async* {}
-}
-''', r'''
-class C {
- foo() sync* {}
-}
-''');
- }
-
- test_class_method_body_block() {
- assertSameSignature(r'''
-class C {
- int foo() {
- return 1;
- }
-}
-''', r'''
-class C {
- int foo() {
- return 2;
- }
-}
-''');
- }
-
- test_class_method_body_block_to_empty() {
- assertNotSameSignature(r'''
-class C {
- void foo() {}
-}
-''', r'''
-class C {
- void foo();
-}
-''');
- }
-
- test_class_method_body_block_to_expression() {
- assertSameSignature(r'''
-class C {
- int foo() {
- return 1;
- }
-}
-''', r'''
-class C {
- int foo() => 2;
-}
-''');
- }
-
- test_class_method_body_empty_to_block() {
- assertNotSameSignature(r'''
-class C {
- void foo();
-}
-''', r'''
-class C {
- void foo() {}
-}
-''');
- }
-
- test_class_method_body_empty_to_expression() {
- assertNotSameSignature(r'''
-class C {
- int foo();
-}
-''', r'''
-class C {
- int foo() => 0;
-}
-''');
- }
-
- test_class_method_body_expression() {
- assertSameSignature(r'''
-class C {
- int foo() => 1;
-}
-''', r'''
-class C {
- int foo() => 2;
-}
-''');
- }
-
- test_class_method_body_expression_to_block() {
- assertSameSignature(r'''
-class C {
- int foo() => 1;
-}
-''', r'''
-class C {
- int foo() {
- return 2;
- }
-}
-''');
- }
-
- test_class_method_body_sync_to_async() {
- assertNotSameSignature(r'''
-class C {
- foo() {}
-}
-''', r'''
-class C {
- foo() async {}
-}
-''');
- }
-
- test_class_method_body_sync_to_syncStar() {
- assertNotSameSignature(r'''
-class C {
- foo() sync* {}
-}
-''', r'''
-class C {
- foo() {}
-}
-''');
- }
-
- test_class_method_body_syncStar_to_sync() {
- assertNotSameSignature(r'''
-class C {
- foo() sync* {}
-}
-''', r'''
-class C {
- foo() {}
-}
-''');
- }
-
- test_class_method_getter_body_block_to_empty() {
- assertNotSameSignature(r'''
-class C {
- int get foo {
- return 1;
- }
-}
-''', r'''
-class C {
- int get foo;
-}
-''');
- }
-
- test_class_method_getter_body_block_to_expression() {
- assertSameSignature(r'''
-class C {
- int get foo {
- return 1;
- }
-}
-''', r'''
-class C {
- int get foo => 2;
-}
-''');
- }
-
- test_class_method_getter_body_empty_to_block() {
- assertNotSameSignature(r'''
-class C {
- int get foo;
-}
-''', r'''
-class C {
- int get foo {
- return 0;
- }
-}
-''');
- }
-
- test_class_method_getter_body_empty_to_expression() {
- assertNotSameSignature(r'''
-class C {
- int get foo;
-}
-''', r'''
-class C {
- int get foo => 0;
-}
-''');
- }
-
- test_class_method_getter_body_expression_to_block() {
- assertSameSignature(r'''
-class C {
- int get foo => 1;
-}
-''', r'''
-class C {
- int get foo {
- return 2;
- }
-}
-''');
- }
-
- test_class_method_getter_body_expression_to_empty() {
- assertNotSameSignature(r'''
-class C {
- int get foo => 0;
-}
-''', r'''
-class C {
- int get foo;
-}
-''');
- }
-
- test_class_method_parameters_add() {
- assertNotSameSignature(r'''
-class C {
- foo(int a) {}
-}
-''', r'''
-class C {
- foo(int a, int b) {}
-}
-''');
- }
-
- test_class_method_parameters_remove() {
- assertNotSameSignature(r'''
-class C {
- foo(int a, int b) {}
-}
-''', r'''
-class C {
- foo(int a) {}
-}
-''');
- }
-
- test_class_method_parameters_rename() {
- assertNotSameSignature(r'''
-class C {
- void foo(int a) {}
-}
-''', r'''
-class C {
- void foo(int b) {}
-}
-''');
- }
-
- test_class_method_parameters_type() {
- assertNotSameSignature(r'''
-class C {
- void foo(int p) {}
-}
-''', r'''
-class C {
- void foo(double p) {}
-}
-''');
- }
-
- test_class_method_returnType() {
- assertNotSameSignature(r'''
-class C {
- int foo() => 0;
-}
-''', r'''
-class C {
- num foo() => 0;
-}
-''');
- }
-
- test_class_method_setter_body_block_to_empty() {
- assertNotSameSignature(r'''
-class C {
- set foo(_) {}
-}
-''', r'''
-class C {
- set foo(_);
-}
-''');
- }
-
- test_class_method_setter_body_empty_to_block() {
- assertNotSameSignature(r'''
-class C {
- set foo(_);
-}
-''', r'''
-class C {
- set foo(_) {}
-}
-''');
- }
-
- test_class_method_typeParameters_add() async {
- assertNotSameSignature(r'''
-class C {
- void foo() {}
-}
-''', r'''
-class C {
- void foo<T>() {}
-}
-''');
- }
-
- test_class_method_typeParameters_remove() {
- assertNotSameSignature(r'''
-class C {
- void foo<T>() {}
-}
-''', r'''
-class C {
- void foo() {}
-}
-''');
- }
-
- test_class_method_typeParameters_rename() {
- assertNotSameSignature(r'''
-class C {
- void foo<T>() {}
-}
-''', r'''
-class C {
- void foo<U>() {}
-}
-''');
- }
-
test_class_modifier() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class C {}
''', r'''
abstract class C {}
@@ -905,7 +365,7 @@
}
test_class_with() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class A {}
class B {}
class C extends A {}
@@ -916,8 +376,165 @@
''');
}
+ test_classLike_field_const_add_outOfOrder_hasFinal() {
+ _assertNotSameSignature_classLike(r'''
+static final f = Object();
+''', r'''
+const
+static final f = Object();
+''');
+ }
+
+ test_classLike_field_final_add() {
+ _assertNotSameSignature_classLike(r'''
+int a = 0;
+''', r'''
+final int a = 0;
+''');
+ }
+
+ test_classLike_field_late_add() {
+ _assertNotSameSignature_classLike(r'''
+int a;
+''', r'''
+late int a;
+''');
+ }
+
+ test_classLike_field_late_remove() {
+ _assertNotSameSignature_classLike(r'''
+late int a;
+''', r'''
+int a;
+''');
+ }
+
+ test_classLike_field_static_add() {
+ _assertNotSameSignature_classLike(r'''
+int a;
+''', r'''
+static int a;
+''');
+ }
+
+ test_classLike_field_withoutType() {
+ _assertNotSameSignature_classLike(r'''
+var a = 1;
+''', r'''
+var a = 2;
+''');
+ }
+
+ test_classLike_field_withoutType2() {
+ _assertNotSameSignature_classLike(r'''
+var a = 1, b = 2, c, d = 4;
+''', r'''
+var a = 1, b, c = 3, d = 4;
+''');
+ }
+
+ test_classLike_field_withType() {
+ _assertSameSignature_classLike(r'''
+int a = 1;
+''', r'''
+int a = 2;
+''');
+ }
+
+ test_classLike_field_withType_const() {
+ _assertNotSameSignature_classLike(r'''
+static const int a = 1;
+''', r'''
+static const int a = 2;
+''');
+ }
+
+ test_classLike_field_withType_final_noConstConstructor() {
+ _assertSameSignature_classLike(r'''
+final int a = 1;
+''', r'''
+final int a = 2;
+''');
+ }
+
+ test_classLike_method_body_block_to_empty() {
+ _assertNotSameSignature_classLike(r'''
+void foo() {}
+''', r'''
+void foo();
+''');
+ }
+
+ test_classLike_method_body_empty_to_block() {
+ _assertNotSameSignature_classLike(r'''
+void foo();
+''', r'''
+void foo() {}
+''');
+ }
+
+ test_classLike_method_body_empty_to_expression() {
+ _assertNotSameSignature_classLike(r'''
+int foo();
+''', r'''
+int foo() => 0;
+''');
+ }
+
+ test_classLike_method_getter_body_block_to_empty() {
+ _assertNotSameSignature_classLike(r'''
+int get foo {
+ return 1;
+}
+''', r'''
+int get foo;
+''');
+ }
+
+ test_classLike_method_getter_body_empty_to_block() {
+ _assertNotSameSignature_classLike(r'''
+int get foo;
+''', r'''
+int get foo {
+ return 0;
+}
+''');
+ }
+
+ test_classLike_method_getter_body_empty_to_expression() {
+ _assertNotSameSignature_classLike(r'''
+int get foo;
+''', r'''
+int get foo => 0;
+''');
+ }
+
+ test_classLike_method_getter_body_expression_to_empty() {
+ _assertNotSameSignature_classLike(r'''
+int get foo => 0;
+''', r'''
+int get foo;
+''');
+ }
+
+ test_classLike_method_setter_body_block_to_empty() {
+ _assertNotSameSignature_classLike(r'''
+set foo(_) {}
+''', r'''
+set foo(_);
+''');
+ }
+
+ test_classLike_method_setter_body_empty_to_block() {
+ _assertNotSameSignature_classLike(r'''
+set foo(_);
+''', r'''
+set foo(_) {}
+''');
+ }
+
test_commentAdd() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
var a = 1;
var b = 2;
var c = 3;
@@ -936,7 +553,7 @@
}
test_commentRemove() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
var a = 1; // comment
/// comment 1
@@ -955,7 +572,7 @@
}
test_directive_library_add() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class A {}
''', r'''
library foo;
@@ -964,7 +581,7 @@
}
test_directive_library_change_name() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
library foo;
class A {}
''', r'''
@@ -974,7 +591,7 @@
}
test_directive_library_change_name_length() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
library foo.bar;
class A {}
''', r'''
@@ -984,7 +601,7 @@
}
test_directive_library_change_name_offset() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
library foo;
class A {}
''', r'''
@@ -994,7 +611,7 @@
}
test_directive_library_remove() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
library foo;
class A {}
''', r'''
@@ -1002,57 +619,49 @@
''');
}
- test_featureSet_add() async {
- assertNotSameSignature(r'''
-class A {}
-''', r'''
-// @dart = 2.5
-class A {}
-''');
- }
-
- test_featureSet_change() async {
- assertNotSameSignature(r'''
-// @dart = 2.6
-class A {}
-''', r'''
-// @dart = 2.2
-class A {}
-''');
- }
-
- test_featureSet_remove() async {
- assertNotSameSignature(r'''
-// @dart = 2.5
-class A {}
-''', r'''
-class A {}
-''');
- }
-
- test_function_annotation() {
- assertNotSameSignature(r'''
-const a = 0;
-
+ test_executable_annotation() {
+ _assertNotSameSignature_executable(r'''
void foo() {}
''', r'''
-const a = 0;
-
@a
void foo() {}
''');
}
- test_function_body_async_to_sync() {
- assertNotSameSignature(r'''
+ test_executable_body_async_to_asyncStar() {
+ _assertNotSameSignature_executable(r'''
+foo() async {}
+''', r'''
+foo() async* {}
+''');
+ }
+
+ test_executable_body_async_to_sync() {
+ _assertNotSameSignature_executable(r'''
foo() async {}
''', r'''
foo() {}
''');
}
- test_function_body_block() {
- assertSameSignature(r'''
+ test_executable_body_asyncStar_to_async() {
+ _assertNotSameSignature_executable(r'''
+foo() async* {}
+''', r'''
+foo() async {}
+''');
+ }
+
+ test_executable_body_asyncStar_to_syncStar() {
+ _assertNotSameSignature_executable(r'''
+foo() async* {}
+''', r'''
+foo() sync* {}
+''');
+ }
+
+ test_executable_body_block() {
+ _assertSameSignature_executable(r'''
int foo() {
return 1;
}
@@ -1063,8 +672,8 @@
''');
}
- test_function_body_block_to_expression() {
- assertSameSignature(r'''
+ test_executable_body_block_to_expression() {
+ _assertSameSignature_executable(r'''
int foo() {
return 1;
}
@@ -1073,32 +682,50 @@
''');
}
- test_function_body_expression() {
- assertSameSignature(r'''
+ test_executable_body_expression() {
+ _assertSameSignature_executable(r'''
int foo() => 1;
''', r'''
int foo() => 2;
''');
}
- test_function_body_sync_to_async() {
- assertNotSameSignature(r'''
+ test_executable_body_expression_to_block() {
+ _assertSameSignature_executable(r'''
+int foo() => 1;
+''', r'''
+int foo() {
+ return 2;
+}
+''');
+ }
+
+ test_executable_body_sync_to_async() {
+ _assertNotSameSignature_executable(r'''
foo() {}
''', r'''
foo() async {}
''');
}
- test_function_body_sync_to_syncStar() {
- assertNotSameSignature(r'''
-foo() {}
-''', r'''
+ test_executable_body_sync_to_syncStar() {
+ _assertNotSameSignature_executable(r'''
foo() sync* {}
+''', r'''
+foo() {}
''');
}
- test_function_getter_block_to_expression() {
- assertSameSignature(r'''
+ test_executable_body_syncStar_to_sync() {
+ _assertNotSameSignature_executable(r'''
+foo() sync* {}
+''', r'''
+foo() {}
+''');
+ }
+
+ test_executable_getter_body_block_to_expression() {
+ _assertSameSignature_executable(r'''
int get foo {
return 1;
}
@@ -1107,56 +734,110 @@
''');
}
- test_function_parameters_rename() {
- assertNotSameSignature(r'''
+ test_executable_getter_body_expression_to_block() {
+ _assertSameSignature_executable(r'''
+int get foo => 1;
+''', r'''
+int get foo {
+ return 2;
+}
+''');
+ }
+
+ test_executable_parameters_add() {
+ _assertNotSameSignature_executable(r'''
+foo(int a) {}
+''', r'''
+foo(int a, int b) {}
+''');
+ }
+
+ test_executable_parameters_remove() {
+ _assertNotSameSignature_executable(r'''
+foo(int a, int b) {}
+''', r'''
+foo(int a) {}
+''');
+ }
+
+ test_executable_parameters_rename() {
+ _assertNotSameSignature_executable(r'''
void foo(int a) {}
''', r'''
void foo(int b) {}
''');
}
- test_function_parameters_type() {
- assertNotSameSignature(r'''
+ test_executable_parameters_type() {
+ _assertNotSameSignature_executable(r'''
void foo(int p) {}
''', r'''
void foo(double p) {}
''');
}
- test_function_returnType() {
- assertNotSameSignature(r'''
+ test_executable_returnType() {
+ _assertNotSameSignature_executable(r'''
int foo() => 0;
''', r'''
num foo() => 0;
''');
}
- test_function_typeParameters_add() {
- assertNotSameSignature(r'''
+ test_executable_typeParameters_add() async {
+ _assertNotSameSignature_executable(r'''
void foo() {}
''', r'''
void foo<T>() {}
''');
}
- test_function_typeParameters_remove() {
- assertNotSameSignature(r'''
+ test_executable_typeParameters_remove() {
+ _assertNotSameSignature_executable(r'''
void foo<T>() {}
''', r'''
void foo() {}
''');
}
- test_function_typeParameters_rename() {
- assertNotSameSignature(r'''
+ test_executable_typeParameters_rename() {
+ _assertNotSameSignature_executable(r'''
void foo<T>() {}
''', r'''
void foo<U>() {}
''');
}
+ test_featureSet_add() async {
+ _assertNotSameSignature(r'''
+class A {}
+''', r'''
+// @dart = 2.5
+class A {}
+''');
+ }
+
+ test_featureSet_change() async {
+ _assertNotSameSignature(r'''
+// @dart = 2.6
+class A {}
+''', r'''
+// @dart = 2.2
+class A {}
+''');
+ }
+
+ test_featureSet_remove() async {
+ _assertNotSameSignature(r'''
+// @dart = 2.5
+class A {}
+''', r'''
+class A {}
+''');
+ }
+
test_issue34850() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
foo
Future<List<int>> bar() {}
''', r'''
@@ -1166,7 +847,7 @@
}
test_mixin_field_withoutType() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
mixin M {
var a = 1;
}
@@ -1178,7 +859,7 @@
}
test_mixin_field_withType() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
mixin M {
int a = 1;
}
@@ -1190,7 +871,7 @@
}
test_mixin_implements() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class A {}
mixin M {}
''', r'''
@@ -1200,7 +881,7 @@
}
test_mixin_method_body_block() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
mixin M {
int foo() {
return 1;
@@ -1216,7 +897,7 @@
}
test_mixin_method_body_expression() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
mixin M {
int foo() => 1;
}
@@ -1228,7 +909,7 @@
}
test_mixin_on() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
class A {}
mixin M {}
''', r'''
@@ -1238,7 +919,7 @@
}
test_topLevelVariable_final_add() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
int a = 0;
''', r'''
final int a = 0;
@@ -1246,7 +927,7 @@
}
test_topLevelVariable_late_add() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
int a;
''', r'''
late int a;
@@ -1254,7 +935,7 @@
}
test_topLevelVariable_late_remove() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
late int a;
''', r'''
int a;
@@ -1262,7 +943,7 @@
}
test_topLevelVariable_withoutType() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
var a = 1;
''', r'''
var a = 2;
@@ -1270,7 +951,7 @@
}
test_topLevelVariable_withoutType2() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
var a = 1, b = 2, c, d = 4;;
''', r'''
var a = 1, b, c = 3, d = 4;;
@@ -1278,7 +959,7 @@
}
test_topLevelVariable_withType() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
int a = 1;
''', r'''
int a = 2;
@@ -1286,7 +967,7 @@
}
test_topLevelVariable_withType_const() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
const int a = 1;
''', r'''
const int a = 2;
@@ -1294,7 +975,7 @@
}
test_topLevelVariable_withType_final() {
- assertSameSignature(r'''
+ _assertSameSignature(r'''
final int a = 1;
''', r'''
final int a = 2;
@@ -1302,7 +983,7 @@
}
test_topLevelVariable_withType_initializer_add() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
int a;
''', r'''
int a = 1;
@@ -1310,7 +991,7 @@
}
test_topLevelVariable_withType_initializer_remove() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
int a = 1;
''', r'''
int a;
@@ -1318,10 +999,84 @@
}
test_typedef_generic_parameters_type() {
- assertNotSameSignature(r'''
+ _assertNotSameSignature(r'''
typedef F = void Function(int);
''', r'''
typedef F = void Function(double);
''');
}
+
+ void _assertNotSameSignature(String oldCode, String newCode) {
+ _assertSignature(oldCode, newCode, same: false);
+ }
+
+ void _assertNotSameSignature_classLike(String oldCode, String newCode) {
+ _assertSignature_classLike(oldCode, newCode, same: false);
+ }
+
+ void _assertNotSameSignature_executable(String oldCode, String newCode) {
+ _assertSignature_executable(oldCode, newCode, same: false);
+ }
+
+ void _assertSameSignature(String oldCode, String newCode) {
+ _assertSignature(oldCode, newCode, same: true);
+ }
+
+ void _assertSameSignature_classLike(String oldCode, String newCode) {
+ _assertSignature_classLike(oldCode, newCode, same: true);
+ }
+
+ void _assertSameSignature_executable(String oldCode, String newCode) {
+ _assertSignature_executable(oldCode, newCode, same: true);
+ }
+
+ void _assertSignature(String oldCode, String newCode, {required bool same}) {
+ var path = convertPath('/test.dart');
+
+ newFile2(path, oldCode);
+ var oldUnit = parseUnit(path).unit;
+ var oldSignature = computeUnlinkedApiSignature(oldUnit);
+
+ newFile2(path, newCode);
+ var newUnit = parseUnit(path).unit;
+ var newSignature = computeUnlinkedApiSignature(newUnit);
+
+ if (same) {
+ expect(newSignature, oldSignature);
+ } else {
+ expect(newSignature, isNot(oldSignature));
+ }
+ }
+
+ void _assertSignature_classLike(
+ String oldCode,
+ String newCode, {
+ required bool same,
+ }) {
+ _assertSignature('''
+class A {
+$oldCode
+}
+''', '''
+class A {
+$newCode
+}
+''', same: same);
+
+ _assertSignature('''
+mixin M {
+$oldCode
+}
+''', '''
+mixin M {
+$newCode
+}
+''', same: same);
+ }
+
+ void _assertSignature_executable(String oldCode, String newCode,
+ {required bool same}) {
+ _assertSignature_classLike(oldCode, newCode, same: same);
+ _assertSignature(oldCode, newCode, same: same);
+ }
}
diff --git a/pkg/compiler/bin/dart2js.dart b/pkg/compiler/bin/dart2js.dart
index 8f26efa..5be8c52 100644
--- a/pkg/compiler/bin/dart2js.dart
+++ b/pkg/compiler/bin/dart2js.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Entrypoint to run the compiler. This entrypoint is currently only used by
/// dart2js developers. To run the compiler you now can:
/// * call `pub get` in the pkg/compiler folder.
diff --git a/pkg/compiler/lib/compiler.dart b/pkg/compiler/lib/compiler.dart
index a57731b..9b2f5c1 100644
--- a/pkg/compiler/lib/compiler.dart
+++ b/pkg/compiler/lib/compiler.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library compiler;
import 'dart:async';
diff --git a/pkg/compiler/lib/src/closure.dart b/pkg/compiler/lib/src/closure.dart
index e5e807e..e5bd068 100644
--- a/pkg/compiler/lib/src/closure.dart
+++ b/pkg/compiler/lib/src/closure.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'common.dart';
import 'elements/entities.dart';
diff --git a/pkg/compiler/lib/src/colors.dart b/pkg/compiler/lib/src/colors.dart
index 4aaae15..f2132cf 100644
--- a/pkg/compiler/lib/src/colors.dart
+++ b/pkg/compiler/lib/src/colors.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.colors;
// See http://en.wikipedia.org/wiki/ANSI_escape_code#CSI_codes
diff --git a/pkg/compiler/lib/src/common.dart b/pkg/compiler/lib/src/common.dart
index cb18897..aa2f28b 100644
--- a/pkg/compiler/lib/src/common.dart
+++ b/pkg/compiler/lib/src/common.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Library that re-exports libraries used throughout the compiler regardless
/// of phase or subfunctionality.
library dart2js.common;
diff --git a/pkg/compiler/lib/src/common/codegen.dart b/pkg/compiler/lib/src/common/codegen.dart
index 0ec9bc0..beb9896 100644
--- a/pkg/compiler/lib/src/common/codegen.dart
+++ b/pkg/compiler/lib/src/common/codegen.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.common.codegen;
import 'package:js_ast/src/precedence.dart' as js show PRIMARY;
diff --git a/pkg/compiler/lib/src/common/elements.dart b/pkg/compiler/lib/src/common/elements.dart
index aea3172..d4e4c7b 100644
--- a/pkg/compiler/lib/src/common/elements.dart
+++ b/pkg/compiler/lib/src/common/elements.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common.dart';
import '../constants/constant_system.dart' as constant_system;
import '../constants/values.dart';
diff --git a/pkg/compiler/lib/src/common/metrics.dart b/pkg/compiler/lib/src/common/metrics.dart
index 458d546..0743946 100644
--- a/pkg/compiler/lib/src/common/metrics.dart
+++ b/pkg/compiler/lib/src/common/metrics.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.common.metrics;
/// A collection of metrics that is normally associated with a task.
diff --git a/pkg/compiler/lib/src/common/names.dart b/pkg/compiler/lib/src/common/names.dart
index 024be8a..ce905a1 100644
--- a/pkg/compiler/lib/src/common/names.dart
+++ b/pkg/compiler/lib/src/common/names.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Library containing identifier, names, and selectors commonly used through
/// the compiler.
library dart2js.common.names;
diff --git a/pkg/compiler/lib/src/common/tasks.dart b/pkg/compiler/lib/src/common/tasks.dart
index 35aff31..52f6a99 100644
--- a/pkg/compiler/lib/src/common/tasks.dart
+++ b/pkg/compiler/lib/src/common/tasks.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.common.tasks;
import 'dart:async'
diff --git a/pkg/compiler/lib/src/common/work.dart b/pkg/compiler/lib/src/common/work.dart
index a36d6b0..c7ca7c9 100644
--- a/pkg/compiler/lib/src/common/work.dart
+++ b/pkg/compiler/lib/src/common/work.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.common.work;
import '../elements/entities.dart' show MemberEntity;
diff --git a/pkg/compiler/lib/src/compiler.dart b/pkg/compiler/lib/src/compiler.dart
index 62f3328..d1999fa 100644
--- a/pkg/compiler/lib/src/compiler.dart
+++ b/pkg/compiler/lib/src/compiler.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.compiler_base;
import 'dart:async' show Future;
diff --git a/pkg/compiler/lib/src/constants/constant_system.dart b/pkg/compiler/lib/src/constants/constant_system.dart
index f50a56d..c1ee3c9 100644
--- a/pkg/compiler/lib/src/constants/constant_system.dart
+++ b/pkg/compiler/lib/src/constants/constant_system.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Constant system following the semantics for Dart code that has been
/// compiled to JavaScript.
library dart2js.constant_system;
diff --git a/pkg/compiler/lib/src/constants/values.dart b/pkg/compiler/lib/src/constants/values.dart
index 885a8bc..a109bc5 100644
--- a/pkg/compiler/lib/src/constants/values.dart
+++ b/pkg/compiler/lib/src/constants/values.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.constants.values;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/dart2js.dart b/pkg/compiler/lib/src/dart2js.dart
index 3c936c66..6c6fd69 100644
--- a/pkg/compiler/lib/src/dart2js.dart
+++ b/pkg/compiler/lib/src/dart2js.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.cmdline;
import 'dart:async' show Future;
diff --git a/pkg/compiler/lib/src/deferred_load/algorithm_state.dart b/pkg/compiler/lib/src/deferred_load/algorithm_state.dart
index 5e1b914..34c13c4 100644
--- a/pkg/compiler/lib/src/deferred_load/algorithm_state.dart
+++ b/pkg/compiler/lib/src/deferred_load/algorithm_state.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'entity_data.dart';
import 'entity_data_info.dart';
import 'import_set.dart';
diff --git a/pkg/compiler/lib/src/deferred_load/deferred_load.dart b/pkg/compiler/lib/src/deferred_load/deferred_load.dart
index 4a5af37..4bbfbdc 100644
--- a/pkg/compiler/lib/src/deferred_load/deferred_load.dart
+++ b/pkg/compiler/lib/src/deferred_load/deferred_load.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// *Overview of deferred loading*
///
/// Deferred loading allows developers to specify deferred imports. These
diff --git a/pkg/compiler/lib/src/deferred_load/entity_data.dart b/pkg/compiler/lib/src/deferred_load/entity_data.dart
index bfb81f2..0751f58 100644
--- a/pkg/compiler/lib/src/deferred_load/entity_data.dart
+++ b/pkg/compiler/lib/src/deferred_load/entity_data.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../constants/values.dart' show ConstantValue;
import '../elements/entities.dart';
diff --git a/pkg/compiler/lib/src/deferred_load/entity_data_info.dart b/pkg/compiler/lib/src/deferred_load/entity_data_info.dart
index 7c0c07d..064a126 100644
--- a/pkg/compiler/lib/src/deferred_load/entity_data_info.dart
+++ b/pkg/compiler/lib/src/deferred_load/entity_data_info.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'package:kernel/type_environment.dart' as ir;
diff --git a/pkg/compiler/lib/src/deferred_load/import_set.dart b/pkg/compiler/lib/src/deferred_load/import_set.dart
index 6b467cf..eaf268e 100644
--- a/pkg/compiler/lib/src/deferred_load/import_set.dart
+++ b/pkg/compiler/lib/src/deferred_load/import_set.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'output_unit.dart';
import 'program_split_constraints/builder.dart' as psc show SetTransition;
diff --git a/pkg/compiler/lib/src/deferred_load/output_unit.dart b/pkg/compiler/lib/src/deferred_load/output_unit.dart
index bd27d06..dd0c7b8 100644
--- a/pkg/compiler/lib/src/deferred_load/output_unit.dart
+++ b/pkg/compiler/lib/src/deferred_load/output_unit.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:front_end/src/api_unstable/dart2js.dart' as fe;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/deferred_load/program_split_constraints/builder.dart b/pkg/compiler/lib/src/deferred_load/program_split_constraints/builder.dart
index 1bd334f..275d178 100644
--- a/pkg/compiler/lib/src/deferred_load/program_split_constraints/builder.dart
+++ b/pkg/compiler/lib/src/deferred_load/program_split_constraints/builder.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:collection';
import 'nodes.dart';
diff --git a/pkg/compiler/lib/src/deferred_load/program_split_constraints/nodes.dart b/pkg/compiler/lib/src/deferred_load/program_split_constraints/nodes.dart
index 17a6904..a32133a 100644
--- a/pkg/compiler/lib/src/deferred_load/program_split_constraints/nodes.dart
+++ b/pkg/compiler/lib/src/deferred_load/program_split_constraints/nodes.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// A [Node] is an abstract base class for all [Node]s parsed from json
/// constraints.
abstract class Node {
diff --git a/pkg/compiler/lib/src/deferred_load/program_split_constraints/parser.dart b/pkg/compiler/lib/src/deferred_load/program_split_constraints/parser.dart
index e60c182..b798f7b 100644
--- a/pkg/compiler/lib/src/deferred_load/program_split_constraints/parser.dart
+++ b/pkg/compiler/lib/src/deferred_load/program_split_constraints/parser.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:convert';
import 'nodes.dart';
diff --git a/pkg/compiler/lib/src/deferred_load/work_queue.dart b/pkg/compiler/lib/src/deferred_load/work_queue.dart
index 9c9c554..072ff66 100644
--- a/pkg/compiler/lib/src/deferred_load/work_queue.dart
+++ b/pkg/compiler/lib/src/deferred_load/work_queue.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:collection' show Queue;
import 'algorithm_state.dart';
diff --git a/pkg/compiler/lib/src/diagnostics/diagnostic_listener.dart b/pkg/compiler/lib/src/diagnostics/diagnostic_listener.dart
index 5fab3db..c889753 100644
--- a/pkg/compiler/lib/src/diagnostics/diagnostic_listener.dart
+++ b/pkg/compiler/lib/src/diagnostics/diagnostic_listener.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.diagnostic_listener;
import '../../compiler.dart' as api;
diff --git a/pkg/compiler/lib/src/diagnostics/invariant.dart b/pkg/compiler/lib/src/diagnostics/invariant.dart
index 04a7947..9986c24 100644
--- a/pkg/compiler/lib/src/diagnostics/invariant.dart
+++ b/pkg/compiler/lib/src/diagnostics/invariant.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.diagnostics.invariant;
import 'spannable.dart';
diff --git a/pkg/compiler/lib/src/diagnostics/messages.dart b/pkg/compiler/lib/src/diagnostics/messages.dart
index 4e3f803..c7a774d 100644
--- a/pkg/compiler/lib/src/diagnostics/messages.dart
+++ b/pkg/compiler/lib/src/diagnostics/messages.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// The messages in this file should follow the [Guide for Writing
/// Diagnostics](../../../../front_end/lib/src/fasta/diagnostics.md).
///
diff --git a/pkg/compiler/lib/src/diagnostics/source_span.dart b/pkg/compiler/lib/src/diagnostics/source_span.dart
index 2b24c11..d180a9b 100644
--- a/pkg/compiler/lib/src/diagnostics/source_span.dart
+++ b/pkg/compiler/lib/src/diagnostics/source_span.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.diagnostics.source_span;
import 'spannable.dart' show Spannable;
diff --git a/pkg/compiler/lib/src/diagnostics/spannable.dart b/pkg/compiler/lib/src/diagnostics/spannable.dart
index 3bb9bf0..3e9da70 100644
--- a/pkg/compiler/lib/src/diagnostics/spannable.dart
+++ b/pkg/compiler/lib/src/diagnostics/spannable.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.diagnostics.spannable;
/// Tagging interface for classes from which source spans can be generated.
diff --git a/pkg/compiler/lib/src/dump_info.dart b/pkg/compiler/lib/src/dump_info.dart
index 35a0e17..92e8499 100644
--- a/pkg/compiler/lib/src/dump_info.dart
+++ b/pkg/compiler/lib/src/dump_info.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dump_info;
import 'dart:convert'
diff --git a/pkg/compiler/lib/src/elements/entities.dart b/pkg/compiler/lib/src/elements/entities.dart
index f8d96a3..d363a30 100644
--- a/pkg/compiler/lib/src/elements/entities.dart
+++ b/pkg/compiler/lib/src/elements/entities.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library entities;
import 'package:front_end/src/api_unstable/dart2js.dart' show AsyncModifier;
diff --git a/pkg/compiler/lib/src/elements/entity_utils.dart b/pkg/compiler/lib/src/elements/entity_utils.dart
index 7e58133..cb548cf 100644
--- a/pkg/compiler/lib/src/elements/entity_utils.dart
+++ b/pkg/compiler/lib/src/elements/entity_utils.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library entity_utils;
import 'package:front_end/src/api_unstable/dart2js.dart'
diff --git a/pkg/compiler/lib/src/elements/indexed.dart b/pkg/compiler/lib/src/elements/indexed.dart
index 4552656..efc5b92 100644
--- a/pkg/compiler/lib/src/elements/indexed.dart
+++ b/pkg/compiler/lib/src/elements/indexed.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Indexed entity interfaces for modeling elements derived from Kernel IR.
import '../elements/entities.dart';
diff --git a/pkg/compiler/lib/src/elements/jumps.dart b/pkg/compiler/lib/src/elements/jumps.dart
index 16fc90f..322ec51 100644
--- a/pkg/compiler/lib/src/elements/jumps.dart
+++ b/pkg/compiler/lib/src/elements/jumps.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library elements.jumps;
import 'entities.dart';
diff --git a/pkg/compiler/lib/src/elements/names.dart b/pkg/compiler/lib/src/elements/names.dart
index c3ff551..84f3e25 100644
--- a/pkg/compiler/lib/src/elements/names.dart
+++ b/pkg/compiler/lib/src/elements/names.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.elements.names;
import 'package:front_end/src/api_unstable/dart2js.dart' show $_;
diff --git a/pkg/compiler/lib/src/elements/operators.dart b/pkg/compiler/lib/src/elements/operators.dart
index 56a3797..89d2876 100644
--- a/pkg/compiler/lib/src/elements/operators.dart
+++ b/pkg/compiler/lib/src/elements/operators.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.operators;
import 'names.dart' show PublicName;
diff --git a/pkg/compiler/lib/src/elements/types.dart b/pkg/compiler/lib/src/elements/types.dart
index a0d63a9..6f5106a 100644
--- a/pkg/compiler/lib/src/elements/types.dart
+++ b/pkg/compiler/lib/src/elements/types.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common/elements.dart';
import '../common/names.dart';
import '../options.dart';
diff --git a/pkg/compiler/lib/src/enqueue.dart b/pkg/compiler/lib/src/enqueue.dart
index e003a60..a664e0d 100644
--- a/pkg/compiler/lib/src/enqueue.dart
+++ b/pkg/compiler/lib/src/enqueue.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.enqueue;
import 'common/elements.dart' show ElementEnvironment;
diff --git a/pkg/compiler/lib/src/environment.dart b/pkg/compiler/lib/src/environment.dart
index cb5fdbd..295f17c 100644
--- a/pkg/compiler/lib/src/environment.dart
+++ b/pkg/compiler/lib/src/environment.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Collects definitions provided to the compiler via the `-D` flag.
///
/// Environment variables can be used in the user code in two ways. From
diff --git a/pkg/compiler/lib/src/hash/sha1.dart b/pkg/compiler/lib/src/hash/sha1.dart
index f34c204..4c4e65b 100644
--- a/pkg/compiler/lib/src/hash/sha1.dart
+++ b/pkg/compiler/lib/src/hash/sha1.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:convert';
import 'package:crypto/crypto.dart';
diff --git a/pkg/compiler/lib/src/inferrer/abstract_value_domain.dart b/pkg/compiler/lib/src/inferrer/abstract_value_domain.dart
index e6d05b1..36752ac 100644
--- a/pkg/compiler/lib/src/inferrer/abstract_value_domain.dart
+++ b/pkg/compiler/lib/src/inferrer/abstract_value_domain.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.abstract_value_domain;
import '../constants/values.dart' show ConstantValue, PrimitiveConstantValue;
diff --git a/pkg/compiler/lib/src/inferrer/builder_kernel.dart b/pkg/compiler/lib/src/inferrer/builder_kernel.dart
index 716ea52..97fc077 100644
--- a/pkg/compiler/lib/src/inferrer/builder_kernel.dart
+++ b/pkg/compiler/lib/src/inferrer/builder_kernel.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../closure.dart';
diff --git a/pkg/compiler/lib/src/inferrer/closure_tracer.dart b/pkg/compiler/lib/src/inferrer/closure_tracer.dart
index 18eb0ca..67c4476 100644
--- a/pkg/compiler/lib/src/inferrer/closure_tracer.dart
+++ b/pkg/compiler/lib/src/inferrer/closure_tracer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library compiler.src.inferrer.closure_tracer;
import '../common/names.dart' show Identifiers, Names;
diff --git a/pkg/compiler/lib/src/inferrer/debug.dart b/pkg/compiler/lib/src/inferrer/debug.dart
index def9a7d..c2bef3e 100644
--- a/pkg/compiler/lib/src/inferrer/debug.dart
+++ b/pkg/compiler/lib/src/inferrer/debug.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Values used only for debugging type inference.
library compiler.src.inferrer.debug;
diff --git a/pkg/compiler/lib/src/inferrer/inferrer_engine.dart b/pkg/compiler/lib/src/inferrer/inferrer_engine.dart
index 3d9dd84..f922fef 100644
--- a/pkg/compiler/lib/src/inferrer/inferrer_engine.dart
+++ b/pkg/compiler/lib/src/inferrer/inferrer_engine.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../../compiler.dart';
diff --git a/pkg/compiler/lib/src/inferrer/list_tracer.dart b/pkg/compiler/lib/src/inferrer/list_tracer.dart
index 4918a33..2617b52 100644
--- a/pkg/compiler/lib/src/inferrer/list_tracer.dart
+++ b/pkg/compiler/lib/src/inferrer/list_tracer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library compiler.src.inferrer.list_tracer;
import '../common/names.dart';
diff --git a/pkg/compiler/lib/src/inferrer/locals_handler.dart b/pkg/compiler/lib/src/inferrer/locals_handler.dart
index 06fb529..2545b2b 100644
--- a/pkg/compiler/lib/src/inferrer/locals_handler.dart
+++ b/pkg/compiler/lib/src/inferrer/locals_handler.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library locals_handler;
import 'dart:collection' show IterableMixin;
diff --git a/pkg/compiler/lib/src/inferrer/map_tracer.dart b/pkg/compiler/lib/src/inferrer/map_tracer.dart
index 70f36d1..f997f1a 100644
--- a/pkg/compiler/lib/src/inferrer/map_tracer.dart
+++ b/pkg/compiler/lib/src/inferrer/map_tracer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library compiler.src.inferrer.map_tracer;
import '../common/names.dart';
diff --git a/pkg/compiler/lib/src/inferrer/node_tracer.dart b/pkg/compiler/lib/src/inferrer/node_tracer.dart
index 8500f56..594a533 100644
--- a/pkg/compiler/lib/src/inferrer/node_tracer.dart
+++ b/pkg/compiler/lib/src/inferrer/node_tracer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library compiler.src.inferrer.node_tracer;
import '../common/names.dart' show Identifiers;
diff --git a/pkg/compiler/lib/src/inferrer/powersets/powerset_bits.dart b/pkg/compiler/lib/src/inferrer/powersets/powerset_bits.dart
index fd657bd..823f59a 100644
--- a/pkg/compiler/lib/src/inferrer/powersets/powerset_bits.dart
+++ b/pkg/compiler/lib/src/inferrer/powersets/powerset_bits.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../../common/elements.dart' show CommonElements;
import '../../constants/values.dart';
import '../../elements/entities.dart';
diff --git a/pkg/compiler/lib/src/inferrer/powersets/powersets.dart b/pkg/compiler/lib/src/inferrer/powersets/powersets.dart
index 6314434..8afeedf 100644
--- a/pkg/compiler/lib/src/inferrer/powersets/powersets.dart
+++ b/pkg/compiler/lib/src/inferrer/powersets/powersets.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../../constants/values.dart' show ConstantValue, PrimitiveConstantValue;
import '../../elements/entities.dart';
import '../../elements/names.dart';
diff --git a/pkg/compiler/lib/src/inferrer/powersets/wrapped.dart b/pkg/compiler/lib/src/inferrer/powersets/wrapped.dart
index 35c2641..f468a23 100644
--- a/pkg/compiler/lib/src/inferrer/powersets/wrapped.dart
+++ b/pkg/compiler/lib/src/inferrer/powersets/wrapped.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../../constants/values.dart' show ConstantValue, PrimitiveConstantValue;
import '../../elements/entities.dart';
import '../../elements/names.dart';
diff --git a/pkg/compiler/lib/src/inferrer/set_tracer.dart b/pkg/compiler/lib/src/inferrer/set_tracer.dart
index df495bf..47e38ae 100644
--- a/pkg/compiler/lib/src/inferrer/set_tracer.dart
+++ b/pkg/compiler/lib/src/inferrer/set_tracer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library compiler.src.inferrer.set_tracer;
import '../common/names.dart';
diff --git a/pkg/compiler/lib/src/inferrer/trivial.dart b/pkg/compiler/lib/src/inferrer/trivial.dart
index c81c91f..e66532e 100644
--- a/pkg/compiler/lib/src/inferrer/trivial.dart
+++ b/pkg/compiler/lib/src/inferrer/trivial.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../constants/values.dart' show ConstantValue, PrimitiveConstantValue;
import '../elements/entities.dart';
import '../elements/names.dart';
diff --git a/pkg/compiler/lib/src/inferrer/type_graph_dump.dart b/pkg/compiler/lib/src/inferrer/type_graph_dump.dart
index 9a0d7e8..c8b80af 100644
--- a/pkg/compiler/lib/src/inferrer/type_graph_dump.dart
+++ b/pkg/compiler/lib/src/inferrer/type_graph_dump.dart
@@ -1,6 +1,9 @@
// Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+
+// @dart = 2.10
+
library dart2js.inferrer.type_graph_dump;
import '../../compiler.dart';
diff --git a/pkg/compiler/lib/src/inferrer/type_graph_inferrer.dart b/pkg/compiler/lib/src/inferrer/type_graph_inferrer.dart
index 97278f3..0e14604 100644
--- a/pkg/compiler/lib/src/inferrer/type_graph_inferrer.dart
+++ b/pkg/compiler/lib/src/inferrer/type_graph_inferrer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library type_graph_inferrer;
import 'dart:collection' show Queue;
diff --git a/pkg/compiler/lib/src/inferrer/type_graph_nodes.dart b/pkg/compiler/lib/src/inferrer/type_graph_nodes.dart
index 334c9cf..cd09b81 100644
--- a/pkg/compiler/lib/src/inferrer/type_graph_nodes.dart
+++ b/pkg/compiler/lib/src/inferrer/type_graph_nodes.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library compiler.src.inferrer.type_graph_nodes;
import 'dart:collection' show IterableBase;
diff --git a/pkg/compiler/lib/src/inferrer/type_system.dart b/pkg/compiler/lib/src/inferrer/type_system.dart
index d45f291..d28d06f 100644
--- a/pkg/compiler/lib/src/inferrer/type_system.dart
+++ b/pkg/compiler/lib/src/inferrer/type_system.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../common.dart';
import '../constants/values.dart' show BoolConstantValue;
diff --git a/pkg/compiler/lib/src/inferrer/typemasks/constants.dart b/pkg/compiler/lib/src/inferrer/typemasks/constants.dart
index e46212b..7684c46 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/constants.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/constants.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library types.constants;
import '../../constants/constant_system.dart' as constant_system;
diff --git a/pkg/compiler/lib/src/inferrer/typemasks/container_type_mask.dart b/pkg/compiler/lib/src/inferrer/typemasks/container_type_mask.dart
index a001c78..6e5d625 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/container_type_mask.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/container_type_mask.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of masks;
/// A [TypeMask] for a specific allocation site of a container (currently only
diff --git a/pkg/compiler/lib/src/inferrer/typemasks/dictionary_type_mask.dart b/pkg/compiler/lib/src/inferrer/typemasks/dictionary_type_mask.dart
index 20adc15..fe414d6 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/dictionary_type_mask.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/dictionary_type_mask.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of masks;
/// A [DictionaryTypeMask] is a [TypeMask] for a specific allocation
diff --git a/pkg/compiler/lib/src/inferrer/typemasks/flat_type_mask.dart b/pkg/compiler/lib/src/inferrer/typemasks/flat_type_mask.dart
index d42d4bd..5611b25 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/flat_type_mask.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/flat_type_mask.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of masks;
enum _FlatTypeMaskKind { empty, exact, subclass, subtype }
diff --git a/pkg/compiler/lib/src/inferrer/typemasks/forwarding_type_mask.dart b/pkg/compiler/lib/src/inferrer/typemasks/forwarding_type_mask.dart
index 213c62a..7b2651b 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/forwarding_type_mask.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/forwarding_type_mask.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of masks;
/// A type mask that wraps another one, and delegates all its
diff --git a/pkg/compiler/lib/src/inferrer/typemasks/map_type_mask.dart b/pkg/compiler/lib/src/inferrer/typemasks/map_type_mask.dart
index 7232e60..22bb146 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/map_type_mask.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/map_type_mask.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of masks;
/// A [MapTypeMask] is a [TypeMask] for a specific allocation
diff --git a/pkg/compiler/lib/src/inferrer/typemasks/masks.dart b/pkg/compiler/lib/src/inferrer/typemasks/masks.dart
index 9de70a3..5b2633f 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/masks.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/masks.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library masks;
import 'package:kernel/ast.dart' as ir;
diff --git a/pkg/compiler/lib/src/inferrer/typemasks/set_type_mask.dart b/pkg/compiler/lib/src/inferrer/typemasks/set_type_mask.dart
index ab01cc4..ece92e5 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/set_type_mask.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/set_type_mask.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of masks;
/// A [SetTypeMask] is a [TypeMask] for a specific allocation site of a set
diff --git a/pkg/compiler/lib/src/inferrer/typemasks/type_mask.dart b/pkg/compiler/lib/src/inferrer/typemasks/type_mask.dart
index 7f8af43..816833c 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/type_mask.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/type_mask.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of masks;
/// An implementation of a [UniverseSelectorConstraints] that is consists if an
diff --git a/pkg/compiler/lib/src/inferrer/typemasks/union_type_mask.dart b/pkg/compiler/lib/src/inferrer/typemasks/union_type_mask.dart
index c9abe7d..a20afb8 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/union_type_mask.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/union_type_mask.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of masks;
class UnionTypeMask extends TypeMask {
diff --git a/pkg/compiler/lib/src/inferrer/typemasks/value_type_mask.dart b/pkg/compiler/lib/src/inferrer/typemasks/value_type_mask.dart
index 61b43de..68c8c69 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/value_type_mask.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/value_type_mask.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of masks;
class ValueTypeMask extends ForwardingTypeMask {
diff --git a/pkg/compiler/lib/src/inferrer/types.dart b/pkg/compiler/lib/src/inferrer/types.dart
index bd2c38d..f5a6405 100644
--- a/pkg/compiler/lib/src/inferrer/types.dart
+++ b/pkg/compiler/lib/src/inferrer/types.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library types;
import 'package:kernel/ast.dart' as ir;
diff --git a/pkg/compiler/lib/src/io/code_output.dart b/pkg/compiler/lib/src/io/code_output.dart
index b5f87ea..a1d8036 100644
--- a/pkg/compiler/lib/src/io/code_output.dart
+++ b/pkg/compiler/lib/src/io/code_output.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.code_output;
import '../../compiler.dart';
diff --git a/pkg/compiler/lib/src/io/kernel_source_information.dart b/pkg/compiler/lib/src/io/kernel_source_information.dart
index 2993f94..1634405 100644
--- a/pkg/compiler/lib/src/io/kernel_source_information.dart
+++ b/pkg/compiler/lib/src/io/kernel_source_information.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Source information system mapping that attempts a semantic mapping between
/// offsets of JavaScript code points to offsets of Dart code points.
diff --git a/pkg/compiler/lib/src/io/location_provider.dart b/pkg/compiler/lib/src/io/location_provider.dart
index b980ee7..72305e7 100644
--- a/pkg/compiler/lib/src/io/location_provider.dart
+++ b/pkg/compiler/lib/src/io/location_provider.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.io.location_provider;
import 'code_output.dart' show CodeOutputListener;
diff --git a/pkg/compiler/lib/src/io/position_information.dart b/pkg/compiler/lib/src/io/position_information.dart
index 5844712..58afd06 100644
--- a/pkg/compiler/lib/src/io/position_information.dart
+++ b/pkg/compiler/lib/src/io/position_information.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Source information system mapping that attempts a semantic mapping between
/// offsets of JavaScript code points to offsets of Dart code points.
diff --git a/pkg/compiler/lib/src/io/source_file.dart b/pkg/compiler/lib/src/io/source_file.dart
index a95008c..be4708b 100644
--- a/pkg/compiler/lib/src/io/source_file.dart
+++ b/pkg/compiler/lib/src/io/source_file.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.io.source_file;
import 'dart:convert' show utf8;
diff --git a/pkg/compiler/lib/src/io/source_information.dart b/pkg/compiler/lib/src/io/source_information.dart
index 9098af0..7c1d64e 100644
--- a/pkg/compiler/lib/src/io/source_information.dart
+++ b/pkg/compiler/lib/src/io/source_information.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.source_information;
import 'package:kernel/ast.dart' as ir;
diff --git a/pkg/compiler/lib/src/io/source_map_builder.dart b/pkg/compiler/lib/src/io/source_map_builder.dart
index d05c9cb..f6c3e3a 100644
--- a/pkg/compiler/lib/src/io/source_map_builder.dart
+++ b/pkg/compiler/lib/src/io/source_map_builder.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.source_map_builder;
import 'package:front_end/src/api_unstable/dart2js.dart' as fe;
diff --git a/pkg/compiler/lib/src/ir/annotations.dart b/pkg/compiler/lib/src/ir/annotations.dart
index c476048..23918ac 100644
--- a/pkg/compiler/lib/src/ir/annotations.dart
+++ b/pkg/compiler/lib/src/ir/annotations.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'package:kernel/type_environment.dart' as ir;
import '../common/names.dart';
diff --git a/pkg/compiler/lib/src/ir/cached_static_type.dart b/pkg/compiler/lib/src/ir/cached_static_type.dart
index 9fdb34b..7c0fa83 100644
--- a/pkg/compiler/lib/src/ir/cached_static_type.dart
+++ b/pkg/compiler/lib/src/ir/cached_static_type.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'package:kernel/type_environment.dart' as ir;
import 'static_type_base.dart';
diff --git a/pkg/compiler/lib/src/ir/closure.dart b/pkg/compiler/lib/src/ir/closure.dart
index 8954f46..20c6948 100644
--- a/pkg/compiler/lib/src/ir/closure.dart
+++ b/pkg/compiler/lib/src/ir/closure.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'package:kernel/src/printer.dart' as ir;
import 'package:kernel/text/ast_to_text.dart' as ir show debugNodeToString;
diff --git a/pkg/compiler/lib/src/ir/constants.dart b/pkg/compiler/lib/src/ir/constants.dart
index 4ac13df..e799ea2 100644
--- a/pkg/compiler/lib/src/ir/constants.dart
+++ b/pkg/compiler/lib/src/ir/constants.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:front_end/src/api_prototype/constant_evaluator.dart' as ir;
import 'package:front_end/src/api_unstable/dart2js.dart' as ir;
import 'package:kernel/ast.dart' as ir;
diff --git a/pkg/compiler/lib/src/ir/element_map.dart b/pkg/compiler/lib/src/ir/element_map.dart
index 8e73cf4..e021596 100644
--- a/pkg/compiler/lib/src/ir/element_map.dart
+++ b/pkg/compiler/lib/src/ir/element_map.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'package:kernel/core_types.dart' as ir;
diff --git a/pkg/compiler/lib/src/ir/impact.dart b/pkg/compiler/lib/src/ir/impact.dart
index 1ea8f86..609256a 100644
--- a/pkg/compiler/lib/src/ir/impact.dart
+++ b/pkg/compiler/lib/src/ir/impact.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'package:kernel/type_environment.dart' as ir;
diff --git a/pkg/compiler/lib/src/ir/impact_data.dart b/pkg/compiler/lib/src/ir/impact_data.dart
index a17c61d..77d8075 100644
--- a/pkg/compiler/lib/src/ir/impact_data.dart
+++ b/pkg/compiler/lib/src/ir/impact_data.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'package:kernel/class_hierarchy.dart' as ir;
import 'package:kernel/type_environment.dart' as ir;
diff --git a/pkg/compiler/lib/src/ir/modular.dart b/pkg/compiler/lib/src/ir/modular.dart
index 24afe70..baa7842 100644
--- a/pkg/compiler/lib/src/ir/modular.dart
+++ b/pkg/compiler/lib/src/ir/modular.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'package:kernel/class_hierarchy.dart' as ir;
import 'package:kernel/type_environment.dart' as ir;
diff --git a/pkg/compiler/lib/src/ir/runtime_type_analysis.dart b/pkg/compiler/lib/src/ir/runtime_type_analysis.dart
index d46b622..06ffbfb 100644
--- a/pkg/compiler/lib/src/ir/runtime_type_analysis.dart
+++ b/pkg/compiler/lib/src/ir/runtime_type_analysis.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../common/names.dart';
diff --git a/pkg/compiler/lib/src/ir/scope.dart b/pkg/compiler/lib/src/ir/scope.dart
index 8bc0a90..cfd2ec9 100644
--- a/pkg/compiler/lib/src/ir/scope.dart
+++ b/pkg/compiler/lib/src/ir/scope.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'closure.dart';
import 'scope_visitor.dart';
diff --git a/pkg/compiler/lib/src/ir/scope_visitor.dart b/pkg/compiler/lib/src/ir/scope_visitor.dart
index 3abbbfd..35f8fee 100644
--- a/pkg/compiler/lib/src/ir/scope_visitor.dart
+++ b/pkg/compiler/lib/src/ir/scope_visitor.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'package:kernel/core_types.dart' as ir;
import 'package:kernel/type_environment.dart' as ir;
diff --git a/pkg/compiler/lib/src/ir/static_type.dart b/pkg/compiler/lib/src/ir/static_type.dart
index 9696343..36cd18c 100644
--- a/pkg/compiler/lib/src/ir/static_type.dart
+++ b/pkg/compiler/lib/src/ir/static_type.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:front_end/src/api_unstable/dart2js.dart'
show operatorFromString;
import 'package:kernel/ast.dart' as ir;
diff --git a/pkg/compiler/lib/src/ir/static_type_base.dart b/pkg/compiler/lib/src/ir/static_type_base.dart
index 2bd9146..f32ff54 100644
--- a/pkg/compiler/lib/src/ir/static_type_base.dart
+++ b/pkg/compiler/lib/src/ir/static_type_base.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'package:kernel/type_environment.dart' as ir;
diff --git a/pkg/compiler/lib/src/ir/static_type_cache.dart b/pkg/compiler/lib/src/ir/static_type_cache.dart
index f389c80..32d2384 100644
--- a/pkg/compiler/lib/src/ir/static_type_cache.dart
+++ b/pkg/compiler/lib/src/ir/static_type_cache.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../serialization/serialization.dart';
diff --git a/pkg/compiler/lib/src/ir/static_type_provider.dart b/pkg/compiler/lib/src/ir/static_type_provider.dart
index 2dc7ace..19245d7 100644
--- a/pkg/compiler/lib/src/ir/static_type_provider.dart
+++ b/pkg/compiler/lib/src/ir/static_type_provider.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
/// Interface for accessing static types on expressions.
diff --git a/pkg/compiler/lib/src/ir/types.dart b/pkg/compiler/lib/src/ir/types.dart
index 114b68c..4242166 100644
--- a/pkg/compiler/lib/src/ir/types.dart
+++ b/pkg/compiler/lib/src/ir/types.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common/elements.dart';
import '../elements/entities.dart';
import '../elements/types.dart';
diff --git a/pkg/compiler/lib/src/ir/util.dart b/pkg/compiler/lib/src/ir/util.dart
index e825b52..359fbfc 100644
--- a/pkg/compiler/lib/src/ir/util.dart
+++ b/pkg/compiler/lib/src/ir/util.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/ir/visitors.dart b/pkg/compiler/lib/src/ir/visitors.dart
index b3d182c2..82b81d6 100644
--- a/pkg/compiler/lib/src/ir/visitors.dart
+++ b/pkg/compiler/lib/src/ir/visitors.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../constants/constant_system.dart' as constant_system;
diff --git a/pkg/compiler/lib/src/js/js.dart b/pkg/compiler/lib/src/js/js.dart
index ac9131a..7e48ef3 100644
--- a/pkg/compiler/lib/src/js/js.dart
+++ b/pkg/compiler/lib/src/js/js.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js;
import 'package:js_ast/js_ast.dart';
diff --git a/pkg/compiler/lib/src/js/js_debug.dart b/pkg/compiler/lib/src/js/js_debug.dart
index 19d6600..df828b6 100644
--- a/pkg/compiler/lib/src/js/js_debug.dart
+++ b/pkg/compiler/lib/src/js/js_debug.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Helper for debug JS nodes.
library js.debug;
diff --git a/pkg/compiler/lib/src/js/js_source_mapping.dart b/pkg/compiler/lib/src/js/js_source_mapping.dart
index 8b53feb..d5b4383 100644
--- a/pkg/compiler/lib/src/js/js_source_mapping.dart
+++ b/pkg/compiler/lib/src/js/js_source_mapping.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js.source_mapping;
import '../io/code_output.dart'
diff --git a/pkg/compiler/lib/src/js/placeholder_safety.dart b/pkg/compiler/lib/src/js/placeholder_safety.dart
index 29fea71..70a44d8 100644
--- a/pkg/compiler/lib/src/js/placeholder_safety.dart
+++ b/pkg/compiler/lib/src/js/placeholder_safety.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js.safety;
import "js.dart" as js;
diff --git a/pkg/compiler/lib/src/js/rewrite_async.dart b/pkg/compiler/lib/src/js/rewrite_async.dart
index 0008046..50c9e00 100644
--- a/pkg/compiler/lib/src/js/rewrite_async.dart
+++ b/pkg/compiler/lib/src/js/rewrite_async.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library rewrite_async;
import 'dart:collection';
diff --git a/pkg/compiler/lib/src/js/size_estimator.dart b/pkg/compiler/lib/src/js/size_estimator.dart
index d081f4c0..7dc9fdf 100644
--- a/pkg/compiler/lib/src/js/size_estimator.dart
+++ b/pkg/compiler/lib/src/js/size_estimator.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js.size_estimator;
import 'package:js_ast/js_ast.dart';
diff --git a/pkg/compiler/lib/src/js_backend/annotations.dart b/pkg/compiler/lib/src/js_backend/annotations.dart
index 6994be7..d1942e9 100644
--- a/pkg/compiler/lib/src/js_backend/annotations.dart
+++ b/pkg/compiler/lib/src/js_backend/annotations.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js_backend.backend.annotations;
import 'package:kernel/ast.dart' as ir;
diff --git a/pkg/compiler/lib/src/js_backend/backend.dart b/pkg/compiler/lib/src/js_backend/backend.dart
index ce19532..b8f099c 100644
--- a/pkg/compiler/lib/src/js_backend/backend.dart
+++ b/pkg/compiler/lib/src/js_backend/backend.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js_backend.backend;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/js_backend/backend_impact.dart b/pkg/compiler/lib/src/js_backend/backend_impact.dart
index 2211c3c..37855c0 100644
--- a/pkg/compiler/lib/src/js_backend/backend_impact.dart
+++ b/pkg/compiler/lib/src/js_backend/backend_impact.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_helpers.impact;
import '../common/elements.dart' show CommonElements, ElementEnvironment;
diff --git a/pkg/compiler/lib/src/js_backend/backend_usage.dart b/pkg/compiler/lib/src/js_backend/backend_usage.dart
index 600075d..245b922 100644
--- a/pkg/compiler/lib/src/js_backend/backend_usage.dart
+++ b/pkg/compiler/lib/src/js_backend/backend_usage.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common.dart';
import '../common/elements.dart';
import '../elements/entities.dart';
diff --git a/pkg/compiler/lib/src/js_backend/checked_mode_helpers.dart b/pkg/compiler/lib/src/js_backend/checked_mode_helpers.dart
index 15f9436..1f84c63 100644
--- a/pkg/compiler/lib/src/js_backend/checked_mode_helpers.dart
+++ b/pkg/compiler/lib/src/js_backend/checked_mode_helpers.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// TODO(39733): This file exists now just to register the use of
// 'boolConversionCheck'. Fix the registration and remove this file.
diff --git a/pkg/compiler/lib/src/js_backend/codegen_listener.dart b/pkg/compiler/lib/src/js_backend/codegen_listener.dart
index 93c1745..6682b3e 100644
--- a/pkg/compiler/lib/src/js_backend/codegen_listener.dart
+++ b/pkg/compiler/lib/src/js_backend/codegen_listener.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js_backend.backend.codegen_listener;
import 'dart:collection';
diff --git a/pkg/compiler/lib/src/js_backend/constant_emitter.dart b/pkg/compiler/lib/src/js_backend/constant_emitter.dart
index 304694a..5b3a396 100644
--- a/pkg/compiler/lib/src/js_backend/constant_emitter.dart
+++ b/pkg/compiler/lib/src/js_backend/constant_emitter.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common.dart';
import '../common/elements.dart';
import '../constants/constant_system.dart' as constant_system;
diff --git a/pkg/compiler/lib/src/js_backend/custom_elements_analysis.dart b/pkg/compiler/lib/src/js_backend/custom_elements_analysis.dart
index 965da61..a542b6c 100644
--- a/pkg/compiler/lib/src/js_backend/custom_elements_analysis.dart
+++ b/pkg/compiler/lib/src/js_backend/custom_elements_analysis.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common/elements.dart';
import '../constants/constant_system.dart' as constant_system;
import '../constants/values.dart';
diff --git a/pkg/compiler/lib/src/js_backend/deferred_holder_expression.dart b/pkg/compiler/lib/src/js_backend/deferred_holder_expression.dart
index 22329a2..22e8329 100644
--- a/pkg/compiler/lib/src/js_backend/deferred_holder_expression.dart
+++ b/pkg/compiler/lib/src/js_backend/deferred_holder_expression.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:js_ast/src/precedence.dart' as js show PRIMARY;
import 'package:front_end/src/api_unstable/dart2js.dart' show $A;
diff --git a/pkg/compiler/lib/src/js_backend/enqueuer.dart b/pkg/compiler/lib/src/js_backend/enqueuer.dart
index 9185917..9238540 100644
--- a/pkg/compiler/lib/src/js_backend/enqueuer.dart
+++ b/pkg/compiler/lib/src/js_backend/enqueuer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js.enqueue;
import 'dart:collection' show Queue;
diff --git a/pkg/compiler/lib/src/js_backend/field_analysis.dart b/pkg/compiler/lib/src/js_backend/field_analysis.dart
index 96c5bf9..299bb33 100644
--- a/pkg/compiler/lib/src/js_backend/field_analysis.dart
+++ b/pkg/compiler/lib/src/js_backend/field_analysis.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'package:kernel/type_environment.dart' as ir;
diff --git a/pkg/compiler/lib/src/js_backend/field_naming_mixin.dart b/pkg/compiler/lib/src/js_backend/field_naming_mixin.dart
index 7f624d1..f237a2b 100644
--- a/pkg/compiler/lib/src/js_backend/field_naming_mixin.dart
+++ b/pkg/compiler/lib/src/js_backend/field_naming_mixin.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of js_backend.namer;
abstract class _MinifiedFieldNamer implements Namer {
diff --git a/pkg/compiler/lib/src/js_backend/frequency_assignment.dart b/pkg/compiler/lib/src/js_backend/frequency_assignment.dart
index b19015e..a145c9b 100644
--- a/pkg/compiler/lib/src/js_backend/frequency_assignment.dart
+++ b/pkg/compiler/lib/src/js_backend/frequency_assignment.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:collection' show SplayTreeMap;
/// Assigns names from [nameSequence] to items using a naive algorithm.
diff --git a/pkg/compiler/lib/src/js_backend/frequency_namer.dart b/pkg/compiler/lib/src/js_backend/frequency_namer.dart
index 9e962530..58bf53f 100644
--- a/pkg/compiler/lib/src/js_backend/frequency_namer.dart
+++ b/pkg/compiler/lib/src/js_backend/frequency_namer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of js_backend.namer;
class FrequencyBasedNamer extends Namer
diff --git a/pkg/compiler/lib/src/js_backend/impact_transformer.dart b/pkg/compiler/lib/src/js_backend/impact_transformer.dart
index 8e0ff82..d0cd046 100644
--- a/pkg/compiler/lib/src/js_backend/impact_transformer.dart
+++ b/pkg/compiler/lib/src/js_backend/impact_transformer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js_backend.backend.impact_transformer;
import '../common/elements.dart';
diff --git a/pkg/compiler/lib/src/js_backend/inferred_data.dart b/pkg/compiler/lib/src/js_backend/inferred_data.dart
index bf12d8c..84a067a 100644
--- a/pkg/compiler/lib/src/js_backend/inferred_data.dart
+++ b/pkg/compiler/lib/src/js_backend/inferred_data.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:collection' show Queue;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/js_backend/interceptor_data.dart b/pkg/compiler/lib/src/js_backend/interceptor_data.dart
index 36052c1..299dd02 100644
--- a/pkg/compiler/lib/src/js_backend/interceptor_data.dart
+++ b/pkg/compiler/lib/src/js_backend/interceptor_data.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js_backend.interceptor_data;
import '../common/elements.dart'
diff --git a/pkg/compiler/lib/src/js_backend/js_backend.dart b/pkg/compiler/lib/src/js_backend/js_backend.dart
index 7a00a6c..22a4147 100644
--- a/pkg/compiler/lib/src/js_backend/js_backend.dart
+++ b/pkg/compiler/lib/src/js_backend/js_backend.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js_backend;
export 'backend.dart';
diff --git a/pkg/compiler/lib/src/js_backend/js_interop_analysis.dart b/pkg/compiler/lib/src/js_backend/js_interop_analysis.dart
index 175290c..a2c42d8 100644
--- a/pkg/compiler/lib/src/js_backend/js_interop_analysis.dart
+++ b/pkg/compiler/lib/src/js_backend/js_interop_analysis.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Analysis to determine how to generate code for typed JavaScript interop.
library compiler.src.js_backend.js_interop_analysis;
diff --git a/pkg/compiler/lib/src/js_backend/minify_namer.dart b/pkg/compiler/lib/src/js_backend/minify_namer.dart
index 07f2138..5d685ee 100644
--- a/pkg/compiler/lib/src/js_backend/minify_namer.dart
+++ b/pkg/compiler/lib/src/js_backend/minify_namer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of js_backend.namer;
/// Assigns JavaScript identifiers to Dart variables, class-names and members.
diff --git a/pkg/compiler/lib/src/js_backend/name_sequence.dart b/pkg/compiler/lib/src/js_backend/name_sequence.dart
index 1f7bdf1..5f97bc8 100644
--- a/pkg/compiler/lib/src/js_backend/name_sequence.dart
+++ b/pkg/compiler/lib/src/js_backend/name_sequence.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:front_end/src/api_unstable/dart2js.dart'
show $0, $9, $A, $Z, $_, $a, $z;
diff --git a/pkg/compiler/lib/src/js_backend/namer.dart b/pkg/compiler/lib/src/js_backend/namer.dart
index b8e9f66..3c4f5fa 100644
--- a/pkg/compiler/lib/src/js_backend/namer.dart
+++ b/pkg/compiler/lib/src/js_backend/namer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js_backend.namer;
import 'package:front_end/src/api_unstable/dart2js.dart'
diff --git a/pkg/compiler/lib/src/js_backend/namer_names.dart b/pkg/compiler/lib/src/js_backend/namer_names.dart
index b549098..85cb341 100644
--- a/pkg/compiler/lib/src/js_backend/namer_names.dart
+++ b/pkg/compiler/lib/src/js_backend/namer_names.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of js_backend.namer;
abstract class _NamerName extends jsAst.Name {
diff --git a/pkg/compiler/lib/src/js_backend/native_data.dart b/pkg/compiler/lib/src/js_backend/native_data.dart
index 6bbf4ea..a2541d2 100644
--- a/pkg/compiler/lib/src/js_backend/native_data.dart
+++ b/pkg/compiler/lib/src/js_backend/native_data.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js_backend.native_data;
import 'package:kernel/ast.dart' as ir;
diff --git a/pkg/compiler/lib/src/js_backend/no_such_method_registry.dart b/pkg/compiler/lib/src/js_backend/no_such_method_registry.dart
index f9c2749..9b9cc0d 100644
--- a/pkg/compiler/lib/src/js_backend/no_such_method_registry.dart
+++ b/pkg/compiler/lib/src/js_backend/no_such_method_registry.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common.dart';
import '../common/elements.dart' show CommonElements;
import '../common/names.dart' show Identifiers, Selectors;
diff --git a/pkg/compiler/lib/src/js_backend/resolution_listener.dart b/pkg/compiler/lib/src/js_backend/resolution_listener.dart
index ca26e30..fcfd352 100644
--- a/pkg/compiler/lib/src/js_backend/resolution_listener.dart
+++ b/pkg/compiler/lib/src/js_backend/resolution_listener.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js_backend.backend.resolution_listener;
import '../common/elements.dart' show KCommonElements, KElementEnvironment;
diff --git a/pkg/compiler/lib/src/js_backend/runtime_types.dart b/pkg/compiler/lib/src/js_backend/runtime_types.dart
index f27a4c4..8f63902 100644
--- a/pkg/compiler/lib/src/js_backend/runtime_types.dart
+++ b/pkg/compiler/lib/src/js_backend/runtime_types.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js_backend.runtime_types;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/js_backend/runtime_types_codegen.dart b/pkg/compiler/lib/src/js_backend/runtime_types_codegen.dart
index f549a6a..260e94b 100644
--- a/pkg/compiler/lib/src/js_backend/runtime_types_codegen.dart
+++ b/pkg/compiler/lib/src/js_backend/runtime_types_codegen.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js_backend.runtime_types_codegen;
import '../elements/entities.dart';
diff --git a/pkg/compiler/lib/src/js_backend/runtime_types_new.dart b/pkg/compiler/lib/src/js_backend/runtime_types_new.dart
index 75fa30e..2f8816e 100644
--- a/pkg/compiler/lib/src/js_backend/runtime_types_new.dart
+++ b/pkg/compiler/lib/src/js_backend/runtime_types_new.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js_backend.runtime_types_new;
import 'package:js_runtime/shared/recipe_syntax.dart';
diff --git a/pkg/compiler/lib/src/js_backend/runtime_types_resolution.dart b/pkg/compiler/lib/src/js_backend/runtime_types_resolution.dart
index 391a9fbcc..365a3f8 100644
--- a/pkg/compiler/lib/src/js_backend/runtime_types_resolution.dart
+++ b/pkg/compiler/lib/src/js_backend/runtime_types_resolution.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library js_backend.runtime_types_resolution;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/js_backend/specialized_checks.dart b/pkg/compiler/lib/src/js_backend/specialized_checks.dart
index b81a547..78d1786 100644
--- a/pkg/compiler/lib/src/js_backend/specialized_checks.dart
+++ b/pkg/compiler/lib/src/js_backend/specialized_checks.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common/elements.dart' show ElementEnvironment, JCommonElements;
import '../deferred_load/output_unit.dart';
import '../elements/entities.dart';
diff --git a/pkg/compiler/lib/src/js_backend/string_abbreviation.dart b/pkg/compiler/lib/src/js_backend/string_abbreviation.dart
index 0e442bd..b41e069 100644
--- a/pkg/compiler/lib/src/js_backend/string_abbreviation.dart
+++ b/pkg/compiler/lib/src/js_backend/string_abbreviation.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:front_end/src/api_unstable/dart2js.dart'
show $0, $9, $A, $Z, $a, $z;
diff --git a/pkg/compiler/lib/src/js_backend/string_reference.dart b/pkg/compiler/lib/src/js_backend/string_reference.dart
index 06d7370..966223b 100644
--- a/pkg/compiler/lib/src/js_backend/string_reference.dart
+++ b/pkg/compiler/lib/src/js_backend/string_reference.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// StringReferences are 'holes' in the generated JavaScript that are filled in
/// by the emitter with code to access a large string.
///
diff --git a/pkg/compiler/lib/src/js_backend/type_reference.dart b/pkg/compiler/lib/src/js_backend/type_reference.dart
index b603532..2f4bc25 100644
--- a/pkg/compiler/lib/src/js_backend/type_reference.dart
+++ b/pkg/compiler/lib/src/js_backend/type_reference.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// TypeReferences are 'holes' in the generated JavaScript that are filled in by
/// the emitter with code to access a type.
///
diff --git a/pkg/compiler/lib/src/js_emitter/class_stub_generator.dart b/pkg/compiler/lib/src/js_emitter/class_stub_generator.dart
index 31cb0a5..78a6912 100644
--- a/pkg/compiler/lib/src/js_emitter/class_stub_generator.dart
+++ b/pkg/compiler/lib/src/js_emitter/class_stub_generator.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.class_stub_generator;
import 'package:js_runtime/shared/embedded_names.dart'
diff --git a/pkg/compiler/lib/src/js_emitter/code_emitter_task.dart b/pkg/compiler/lib/src/js_emitter/code_emitter_task.dart
index bc491ae..1cbf7e1 100644
--- a/pkg/compiler/lib/src/js_emitter/code_emitter_task.dart
+++ b/pkg/compiler/lib/src/js_emitter/code_emitter_task.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.code_emitter_task;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/js_emitter/constant_ordering.dart b/pkg/compiler/lib/src/js_emitter/constant_ordering.dart
index 09a8b4f..ed04b1c 100644
--- a/pkg/compiler/lib/src/js_emitter/constant_ordering.dart
+++ b/pkg/compiler/lib/src/js_emitter/constant_ordering.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.constant_ordering;
import '../constants/values.dart';
diff --git a/pkg/compiler/lib/src/js_emitter/headers.dart b/pkg/compiler/lib/src/js_emitter/headers.dart
index 90e4098..66df30c 100644
--- a/pkg/compiler/lib/src/js_emitter/headers.dart
+++ b/pkg/compiler/lib/src/js_emitter/headers.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.headers;
import '../options.dart';
diff --git a/pkg/compiler/lib/src/js_emitter/instantiation_stub_generator.dart b/pkg/compiler/lib/src/js_emitter/instantiation_stub_generator.dart
index 3ab380f..9aadb62 100644
--- a/pkg/compiler/lib/src/js_emitter/instantiation_stub_generator.dart
+++ b/pkg/compiler/lib/src/js_emitter/instantiation_stub_generator.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.instantiation_stub_generator;
import '../common/elements.dart' show JCommonElements, JElementEnvironment;
diff --git a/pkg/compiler/lib/src/js_emitter/interceptor_stub_generator.dart b/pkg/compiler/lib/src/js_emitter/interceptor_stub_generator.dart
index 1324ece..4d5beaf 100644
--- a/pkg/compiler/lib/src/js_emitter/interceptor_stub_generator.dart
+++ b/pkg/compiler/lib/src/js_emitter/interceptor_stub_generator.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.interceptor_stub_generator;
import 'package:js_runtime/shared/embedded_names.dart' as embeddedNames;
diff --git a/pkg/compiler/lib/src/js_emitter/js_emitter.dart b/pkg/compiler/lib/src/js_emitter/js_emitter.dart
index b5d4f85..2371dee 100644
--- a/pkg/compiler/lib/src/js_emitter/js_emitter.dart
+++ b/pkg/compiler/lib/src/js_emitter/js_emitter.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter;
export 'class_stub_generator.dart';
diff --git a/pkg/compiler/lib/src/js_emitter/main_call_stub_generator.dart b/pkg/compiler/lib/src/js_emitter/main_call_stub_generator.dart
index 724da21..fe6ef0c 100644
--- a/pkg/compiler/lib/src/js_emitter/main_call_stub_generator.dart
+++ b/pkg/compiler/lib/src/js_emitter/main_call_stub_generator.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.main_call_stub_generator;
import 'package:js_runtime/shared/embedded_names.dart' as embeddedNames;
diff --git a/pkg/compiler/lib/src/js_emitter/metadata_collector.dart b/pkg/compiler/lib/src/js_emitter/metadata_collector.dart
index c88217e..ae10aaa 100644
--- a/pkg/compiler/lib/src/js_emitter/metadata_collector.dart
+++ b/pkg/compiler/lib/src/js_emitter/metadata_collector.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.metadata_collector;
import 'package:js_ast/src/precedence.dart' as js_precedence;
diff --git a/pkg/compiler/lib/src/js_emitter/model.dart b/pkg/compiler/lib/src/js_emitter/model.dart
index 39fa4eb..a862f48 100644
--- a/pkg/compiler/lib/src/js_emitter/model.dart
+++ b/pkg/compiler/lib/src/js_emitter/model.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.new_js_emitter.model;
import '../common/elements.dart';
diff --git a/pkg/compiler/lib/src/js_emitter/native_emitter.dart b/pkg/compiler/lib/src/js_emitter/native_emitter.dart
index a288989..491d2b2 100644
--- a/pkg/compiler/lib/src/js_emitter/native_emitter.dart
+++ b/pkg/compiler/lib/src/js_emitter/native_emitter.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.native_emitter;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/js_emitter/native_generator.dart b/pkg/compiler/lib/src/js_emitter/native_generator.dart
index 28616dc..71e6414 100644
--- a/pkg/compiler/lib/src/js_emitter/native_generator.dart
+++ b/pkg/compiler/lib/src/js_emitter/native_generator.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.native_generator;
import 'package:js_runtime/shared/embedded_names.dart' as embeddedNames;
diff --git a/pkg/compiler/lib/src/js_emitter/parameter_stub_generator.dart b/pkg/compiler/lib/src/js_emitter/parameter_stub_generator.dart
index fea65fb..7361ff0 100644
--- a/pkg/compiler/lib/src/js_emitter/parameter_stub_generator.dart
+++ b/pkg/compiler/lib/src/js_emitter/parameter_stub_generator.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.parameter_stub_generator;
import '../common/elements.dart' show JElementEnvironment;
diff --git a/pkg/compiler/lib/src/js_emitter/program_builder/collector.dart b/pkg/compiler/lib/src/js_emitter/program_builder/collector.dart
index fea4949..ddd6c60c 100644
--- a/pkg/compiler/lib/src/js_emitter/program_builder/collector.dart
+++ b/pkg/compiler/lib/src/js_emitter/program_builder/collector.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of dart2js.js_emitter.program_builder;
/// Generates the code for all used classes in the program. Static fields (even
diff --git a/pkg/compiler/lib/src/js_emitter/program_builder/field_visitor.dart b/pkg/compiler/lib/src/js_emitter/program_builder/field_visitor.dart
index af94f35..8bd412e 100644
--- a/pkg/compiler/lib/src/js_emitter/program_builder/field_visitor.dart
+++ b/pkg/compiler/lib/src/js_emitter/program_builder/field_visitor.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of dart2js.js_emitter.program_builder;
/// [member] is an instance field.
diff --git a/pkg/compiler/lib/src/js_emitter/program_builder/program_builder.dart b/pkg/compiler/lib/src/js_emitter/program_builder/program_builder.dart
index d04ed4a..5068dda 100644
--- a/pkg/compiler/lib/src/js_emitter/program_builder/program_builder.dart
+++ b/pkg/compiler/lib/src/js_emitter/program_builder/program_builder.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.program_builder;
import '../../common.dart';
diff --git a/pkg/compiler/lib/src/js_emitter/program_builder/registry.dart b/pkg/compiler/lib/src/js_emitter/program_builder/registry.dart
index 78e6cd2..4c77d92 100644
--- a/pkg/compiler/lib/src/js_emitter/program_builder/registry.dart
+++ b/pkg/compiler/lib/src/js_emitter/program_builder/registry.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of dart2js.js_emitter.program_builder;
class LibraryContents {
diff --git a/pkg/compiler/lib/src/js_emitter/runtime_type_generator.dart b/pkg/compiler/lib/src/js_emitter/runtime_type_generator.dart
index 011f679..7086f45 100644
--- a/pkg/compiler/lib/src/js_emitter/runtime_type_generator.dart
+++ b/pkg/compiler/lib/src/js_emitter/runtime_type_generator.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.runtime_type_generator;
import '../common/elements.dart' show CommonElements;
diff --git a/pkg/compiler/lib/src/js_emitter/sorter.dart b/pkg/compiler/lib/src/js_emitter/sorter.dart
index 0de3e33..fa27579 100644
--- a/pkg/compiler/lib/src/js_emitter/sorter.dart
+++ b/pkg/compiler/lib/src/js_emitter/sorter.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.sorter;
import '../elements/entities.dart';
diff --git a/pkg/compiler/lib/src/js_emitter/startup_emitter/emitter.dart b/pkg/compiler/lib/src/js_emitter/startup_emitter/emitter.dart
index 09d0938..7136d66 100644
--- a/pkg/compiler/lib/src/js_emitter/startup_emitter/emitter.dart
+++ b/pkg/compiler/lib/src/js_emitter/startup_emitter/emitter.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.startup_emitter;
import '../../../compiler.dart';
diff --git a/pkg/compiler/lib/src/js_emitter/startup_emitter/fragment_emitter.dart b/pkg/compiler/lib/src/js_emitter/startup_emitter/fragment_emitter.dart
index adb19b0..66db107 100644
--- a/pkg/compiler/lib/src/js_emitter/startup_emitter/fragment_emitter.dart
+++ b/pkg/compiler/lib/src/js_emitter/startup_emitter/fragment_emitter.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of dart2js.js_emitter.startup_emitter.model_emitter;
/// The fast startup emitter's goal is to minimize the amount of work that the
diff --git a/pkg/compiler/lib/src/js_emitter/startup_emitter/fragment_merger.dart b/pkg/compiler/lib/src/js_emitter/startup_emitter/fragment_merger.dart
index 6a92212..f74885d 100644
--- a/pkg/compiler/lib/src/js_emitter/startup_emitter/fragment_merger.dart
+++ b/pkg/compiler/lib/src/js_emitter/startup_emitter/fragment_merger.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:collection';
import '../../common/elements.dart' show ElementEnvironment;
import '../../deferred_load/output_unit.dart'
diff --git a/pkg/compiler/lib/src/js_emitter/startup_emitter/model_emitter.dart b/pkg/compiler/lib/src/js_emitter/startup_emitter/model_emitter.dart
index 133789f..7bd5937 100644
--- a/pkg/compiler/lib/src/js_emitter/startup_emitter/model_emitter.dart
+++ b/pkg/compiler/lib/src/js_emitter/startup_emitter/model_emitter.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_emitter.startup_emitter.model_emitter;
import 'dart:convert' show JsonEncoder;
diff --git a/pkg/compiler/lib/src/js_model/closure.dart b/pkg/compiler/lib/src/js_model/closure.dart
index 62b1101..d8e2b26 100644
--- a/pkg/compiler/lib/src/js_model/closure.dart
+++ b/pkg/compiler/lib/src/js_model/closure.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../closure.dart';
diff --git a/pkg/compiler/lib/src/js_model/element_map.dart b/pkg/compiler/lib/src/js_model/element_map.dart
index 985d77f..2994fbe 100644
--- a/pkg/compiler/lib/src/js_model/element_map.dart
+++ b/pkg/compiler/lib/src/js_model/element_map.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/js_model/element_map_impl.dart b/pkg/compiler/lib/src/js_model/element_map_impl.dart
index 5b30ba7..6bff96f 100644
--- a/pkg/compiler/lib/src/js_model/element_map_impl.dart
+++ b/pkg/compiler/lib/src/js_model/element_map_impl.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:front_end/src/api_prototype/constant_evaluator.dart' as ir;
import 'package:front_end/src/api_unstable/dart2js.dart' as ir;
diff --git a/pkg/compiler/lib/src/js_model/elements.dart b/pkg/compiler/lib/src/js_model/elements.dart
index 01c50f9..aab30db 100644
--- a/pkg/compiler/lib/src/js_model/elements.dart
+++ b/pkg/compiler/lib/src/js_model/elements.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_model.elements;
import '../common/names.dart' show Names;
diff --git a/pkg/compiler/lib/src/js_model/env.dart b/pkg/compiler/lib/src/js_model/env.dart
index a60b310..258eb0f 100644
--- a/pkg/compiler/lib/src/js_model/env.dart
+++ b/pkg/compiler/lib/src/js_model/env.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_model.env;
import 'package:kernel/ast.dart' as ir;
diff --git a/pkg/compiler/lib/src/js_model/js_strategy.dart b/pkg/compiler/lib/src/js_model/js_strategy.dart
index 534f422..95fb87e 100644
--- a/pkg/compiler/lib/src/js_model/js_strategy.dart
+++ b/pkg/compiler/lib/src/js_model/js_strategy.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_model.strategy;
import 'package:kernel/ast.dart' as ir;
diff --git a/pkg/compiler/lib/src/js_model/js_world.dart b/pkg/compiler/lib/src/js_model/js_world.dart
index e6803aa..6b64172 100644
--- a/pkg/compiler/lib/src/js_model/js_world.dart
+++ b/pkg/compiler/lib/src/js_model/js_world.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'package:front_end/src/api_unstable/dart2js.dart' show Link;
diff --git a/pkg/compiler/lib/src/js_model/js_world_builder.dart b/pkg/compiler/lib/src/js_model/js_world_builder.dart
index 2faf6e6..2609fe2 100644
--- a/pkg/compiler/lib/src/js_model/js_world_builder.dart
+++ b/pkg/compiler/lib/src/js_model/js_world_builder.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../closure.dart';
diff --git a/pkg/compiler/lib/src/js_model/locals.dart b/pkg/compiler/lib/src/js_model/locals.dart
index ff38486..b6d3d6b 100644
--- a/pkg/compiler/lib/src/js_model/locals.dart
+++ b/pkg/compiler/lib/src/js_model/locals.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_model.locals;
import 'package:kernel/ast.dart' as ir;
diff --git a/pkg/compiler/lib/src/js_model/type_recipe.dart b/pkg/compiler/lib/src/js_model/type_recipe.dart
index 590ef0a..3a84def 100644
--- a/pkg/compiler/lib/src/js_model/type_recipe.dart
+++ b/pkg/compiler/lib/src/js_model/type_recipe.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.js_model.type_recipe;
import '../elements/entities.dart' show ClassEntity;
diff --git a/pkg/compiler/lib/src/kernel/element_map.dart b/pkg/compiler/lib/src/kernel/element_map.dart
index 3f30198..14ef134 100644
--- a/pkg/compiler/lib/src/kernel/element_map.dart
+++ b/pkg/compiler/lib/src/kernel/element_map.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
// TODO(joshualitt): Merge the contents of element_map_impl.dart into this file.
diff --git a/pkg/compiler/lib/src/kernel/element_map_impl.dart b/pkg/compiler/lib/src/kernel/element_map_impl.dart
index 6dc3606..4b9a722 100644
--- a/pkg/compiler/lib/src/kernel/element_map_impl.dart
+++ b/pkg/compiler/lib/src/kernel/element_map_impl.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:front_end/src/api_prototype/constant_evaluator.dart' as ir;
import 'package:front_end/src/api_unstable/dart2js.dart' as ir;
import 'package:js_runtime/shared/embedded_names.dart';
diff --git a/pkg/compiler/lib/src/kernel/env.dart b/pkg/compiler/lib/src/kernel/env.dart
index 2fe73fc..5829b7d 100644
--- a/pkg/compiler/lib/src/kernel/env.dart
+++ b/pkg/compiler/lib/src/kernel/env.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.kernel.env;
import 'package:front_end/src/api_unstable/dart2js.dart'
diff --git a/pkg/compiler/lib/src/kernel/front_end_adapter.dart b/pkg/compiler/lib/src/kernel/front_end_adapter.dart
index 5dca150..1643703 100644
--- a/pkg/compiler/lib/src/kernel/front_end_adapter.dart
+++ b/pkg/compiler/lib/src/kernel/front_end_adapter.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Helper classes and methods to adapt between `package:compiler` and
/// `package:front_end` APIs.
library compiler.kernel.front_end_adapter;
diff --git a/pkg/compiler/lib/src/kernel/kelements.dart b/pkg/compiler/lib/src/kernel/kelements.dart
index d709a75..8d37d9f 100644
--- a/pkg/compiler/lib/src/kernel/kelements.dart
+++ b/pkg/compiler/lib/src/kernel/kelements.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Entity model for elements derived from Kernel IR.
import 'package:kernel/ast.dart' as ir;
diff --git a/pkg/compiler/lib/src/kernel/kernel_impact.dart b/pkg/compiler/lib/src/kernel/kernel_impact.dart
index 11fa918..6b135bc 100644
--- a/pkg/compiler/lib/src/kernel/kernel_impact.dart
+++ b/pkg/compiler/lib/src/kernel/kernel_impact.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import 'package:kernel/type_environment.dart' as ir;
diff --git a/pkg/compiler/lib/src/kernel/kernel_strategy.dart b/pkg/compiler/lib/src/kernel/kernel_strategy.dart
index 6c29404..137a26c 100644
--- a/pkg/compiler/lib/src/kernel/kernel_strategy.dart
+++ b/pkg/compiler/lib/src/kernel/kernel_strategy.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.kernel.frontend_strategy;
import 'package:kernel/ast.dart' as ir;
diff --git a/pkg/compiler/lib/src/kernel/kernel_world.dart b/pkg/compiler/lib/src/kernel/kernel_world.dart
index 484ab9a..8aede80 100644
--- a/pkg/compiler/lib/src/kernel/kernel_world.dart
+++ b/pkg/compiler/lib/src/kernel/kernel_world.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common.dart';
import '../common/elements.dart';
import '../common/names.dart';
diff --git a/pkg/compiler/lib/src/kernel/native_basic_data.dart b/pkg/compiler/lib/src/kernel/native_basic_data.dart
index df000a3..b80a7c7 100644
--- a/pkg/compiler/lib/src/kernel/native_basic_data.dart
+++ b/pkg/compiler/lib/src/kernel/native_basic_data.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/kernel/no_such_method_resolver.dart b/pkg/compiler/lib/src/kernel/no_such_method_resolver.dart
index 6b44875..165a67a 100644
--- a/pkg/compiler/lib/src/kernel/no_such_method_resolver.dart
+++ b/pkg/compiler/lib/src/kernel/no_such_method_resolver.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../common/elements.dart';
diff --git a/pkg/compiler/lib/src/native/behavior.dart b/pkg/compiler/lib/src/native/behavior.dart
index cf696e9..cde763a 100644
--- a/pkg/compiler/lib/src/native/behavior.dart
+++ b/pkg/compiler/lib/src/native/behavior.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common.dart';
import '../common/elements.dart' show CommonElements, ElementEnvironment;
import '../constants/values.dart';
diff --git a/pkg/compiler/lib/src/native/enqueue.dart b/pkg/compiler/lib/src/native/enqueue.dart
index d70d471..f50379f 100644
--- a/pkg/compiler/lib/src/native/enqueue.dart
+++ b/pkg/compiler/lib/src/native/enqueue.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common/elements.dart' show CommonElements, ElementEnvironment;
import '../elements/entities.dart';
import '../elements/types.dart';
diff --git a/pkg/compiler/lib/src/native/js.dart b/pkg/compiler/lib/src/native/js.dart
index 295dd0b..9c69ae7 100644
--- a/pkg/compiler/lib/src/native/js.dart
+++ b/pkg/compiler/lib/src/native/js.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../js/js.dart' as js;
import '../universe/side_effects.dart' show SideEffects;
import 'behavior.dart';
diff --git a/pkg/compiler/lib/src/native/resolver.dart b/pkg/compiler/lib/src/native/resolver.dart
index b579393..051995e 100644
--- a/pkg/compiler/lib/src/native/resolver.dart
+++ b/pkg/compiler/lib/src/native/resolver.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common.dart';
import '../common/elements.dart' show KElementEnvironment;
import '../constants/values.dart';
diff --git a/pkg/compiler/lib/src/null_compiler_output.dart b/pkg/compiler/lib/src/null_compiler_output.dart
index 497bf50..0ea46dd 100644
--- a/pkg/compiler/lib/src/null_compiler_output.dart
+++ b/pkg/compiler/lib/src/null_compiler_output.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Null pattern implementation of the [CompilerOutput] interface.
library compiler.null_api;
diff --git a/pkg/compiler/lib/src/ordered_typeset.dart b/pkg/compiler/lib/src/ordered_typeset.dart
index 34232db..148fc9a 100644
--- a/pkg/compiler/lib/src/ordered_typeset.dart
+++ b/pkg/compiler/lib/src/ordered_typeset.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library ordered_typeset;
import 'package:front_end/src/api_unstable/dart2js.dart'
diff --git a/pkg/compiler/lib/src/phase/load_kernel.dart b/pkg/compiler/lib/src/phase/load_kernel.dart
index e16d5fb..ee33403 100644
--- a/pkg/compiler/lib/src/phase/load_kernel.dart
+++ b/pkg/compiler/lib/src/phase/load_kernel.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:async';
import 'package:front_end/src/fasta/kernel/utils.dart';
diff --git a/pkg/compiler/lib/src/phase/modular_analysis.dart b/pkg/compiler/lib/src/phase/modular_analysis.dart
index d7ba441..75853c4 100644
--- a/pkg/compiler/lib/src/phase/modular_analysis.dart
+++ b/pkg/compiler/lib/src/phase/modular_analysis.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/resolution/enqueuer.dart b/pkg/compiler/lib/src/resolution/enqueuer.dart
index 6a20e9d..ecc794c 100644
--- a/pkg/compiler/lib/src/resolution/enqueuer.dart
+++ b/pkg/compiler/lib/src/resolution/enqueuer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:collection' show Queue;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/script.dart b/pkg/compiler/lib/src/script.dart
index cacd79f..01a40dc 100644
--- a/pkg/compiler/lib/src/script.dart
+++ b/pkg/compiler/lib/src/script.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.script;
import 'io/source_file.dart';
diff --git a/pkg/compiler/lib/src/serialization/binary_sink.dart b/pkg/compiler/lib/src/serialization/binary_sink.dart
index 7817a31..c5c52a7 100644
--- a/pkg/compiler/lib/src/serialization/binary_sink.dart
+++ b/pkg/compiler/lib/src/serialization/binary_sink.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of 'serialization.dart';
/// [DataSink] that writes data as a sequence of bytes.
diff --git a/pkg/compiler/lib/src/serialization/binary_source.dart b/pkg/compiler/lib/src/serialization/binary_source.dart
index 149f362..00d1291 100644
--- a/pkg/compiler/lib/src/serialization/binary_source.dart
+++ b/pkg/compiler/lib/src/serialization/binary_source.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of 'serialization.dart';
/// [DataSource] that reads data from a sequence of bytes.
diff --git a/pkg/compiler/lib/src/serialization/helpers.dart b/pkg/compiler/lib/src/serialization/helpers.dart
index 81b2e20..08d77ed 100644
--- a/pkg/compiler/lib/src/serialization/helpers.dart
+++ b/pkg/compiler/lib/src/serialization/helpers.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of 'serialization.dart';
/// Enum values used for identifying different kinds of serialized data.
diff --git a/pkg/compiler/lib/src/serialization/member_data.dart b/pkg/compiler/lib/src/serialization/member_data.dart
index 87db36b..7e780fd 100644
--- a/pkg/compiler/lib/src/serialization/member_data.dart
+++ b/pkg/compiler/lib/src/serialization/member_data.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of 'serialization.dart';
/// Helper for looking up object library data from an [ir.Component] node.
diff --git a/pkg/compiler/lib/src/serialization/node_indexer.dart b/pkg/compiler/lib/src/serialization/node_indexer.dart
index 377eb80..a61c244 100644
--- a/pkg/compiler/lib/src/serialization/node_indexer.dart
+++ b/pkg/compiler/lib/src/serialization/node_indexer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of 'serialization.dart';
/// Visitor that ascribes an index to all [ir.TreeNode]s that potentially
diff --git a/pkg/compiler/lib/src/serialization/object_sink.dart b/pkg/compiler/lib/src/serialization/object_sink.dart
index 1388dc6..d5b54b4 100644
--- a/pkg/compiler/lib/src/serialization/object_sink.dart
+++ b/pkg/compiler/lib/src/serialization/object_sink.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of 'serialization.dart';
/// [DataSinkWriter] that writes to a list of objects, useful for debugging
diff --git a/pkg/compiler/lib/src/serialization/object_source.dart b/pkg/compiler/lib/src/serialization/object_source.dart
index 01b602b..bc34994 100644
--- a/pkg/compiler/lib/src/serialization/object_source.dart
+++ b/pkg/compiler/lib/src/serialization/object_source.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of 'serialization.dart';
/// [DataSource] that read from a list of objects, useful for debugging
diff --git a/pkg/compiler/lib/src/serialization/serialization.dart b/pkg/compiler/lib/src/serialization/serialization.dart
index b7747d9..016192a 100644
--- a/pkg/compiler/lib/src/serialization/serialization.dart
+++ b/pkg/compiler/lib/src/serialization/serialization.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:convert';
import 'dart:typed_data';
import 'package:kernel/ast.dart' as ir;
diff --git a/pkg/compiler/lib/src/serialization/sink.dart b/pkg/compiler/lib/src/serialization/sink.dart
index 3158728..83a5af9 100644
--- a/pkg/compiler/lib/src/serialization/sink.dart
+++ b/pkg/compiler/lib/src/serialization/sink.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of 'serialization.dart';
/// Interface handling [DataSinkWriter] low-level data serialization.
diff --git a/pkg/compiler/lib/src/serialization/source.dart b/pkg/compiler/lib/src/serialization/source.dart
index b43c1ad..ee1b7e0 100644
--- a/pkg/compiler/lib/src/serialization/source.dart
+++ b/pkg/compiler/lib/src/serialization/source.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
part of 'serialization.dart';
/// Interface handling [DataSourceReader] low-level data deserialization.
diff --git a/pkg/compiler/lib/src/serialization/strategies.dart b/pkg/compiler/lib/src/serialization/strategies.dart
index d73bddd..11ebe03 100644
--- a/pkg/compiler/lib/src/serialization/strategies.dart
+++ b/pkg/compiler/lib/src/serialization/strategies.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:io';
import 'package:front_end/src/fasta/kernel/utils.dart' as ir
diff --git a/pkg/compiler/lib/src/serialization/task.dart b/pkg/compiler/lib/src/serialization/task.dart
index c69d158..9c39ef3 100644
--- a/pkg/compiler/lib/src/serialization/task.dart
+++ b/pkg/compiler/lib/src/serialization/task.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:async';
import 'package:kernel/ast.dart' as ir;
import 'package:kernel/binary/ast_from_binary.dart' as ir;
diff --git a/pkg/compiler/lib/src/source_file_provider.dart b/pkg/compiler/lib/src/source_file_provider.dart
index 4ab19c1..4099ddc 100644
--- a/pkg/compiler/lib/src/source_file_provider.dart
+++ b/pkg/compiler/lib/src/source_file_provider.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library source_file_provider;
import 'dart:async';
diff --git a/pkg/compiler/lib/src/ssa/builder_kernel.dart b/pkg/compiler/lib/src/ssa/builder_kernel.dart
index 8109b5f..c34f02f 100644
--- a/pkg/compiler/lib/src/ssa/builder_kernel.dart
+++ b/pkg/compiler/lib/src/ssa/builder_kernel.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:js_runtime/shared/embedded_names.dart';
import 'package:kernel/ast.dart' as ir;
diff --git a/pkg/compiler/lib/src/ssa/codegen.dart b/pkg/compiler/lib/src/ssa/codegen.dart
index d54ffe8..f5e81f0 100644
--- a/pkg/compiler/lib/src/ssa/codegen.dart
+++ b/pkg/compiler/lib/src/ssa/codegen.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:math' as math;
import 'dart:collection' show Queue;
diff --git a/pkg/compiler/lib/src/ssa/codegen_helpers.dart b/pkg/compiler/lib/src/ssa/codegen_helpers.dart
index b1a37fb..600cbac 100644
--- a/pkg/compiler/lib/src/ssa/codegen_helpers.dart
+++ b/pkg/compiler/lib/src/ssa/codegen_helpers.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../constants/values.dart';
import '../elements/entities.dart';
import '../inferrer/abstract_value_domain.dart';
diff --git a/pkg/compiler/lib/src/ssa/interceptor_finalizer.dart b/pkg/compiler/lib/src/ssa/interceptor_finalizer.dart
index b8dcd74..45e2c3b 100644
--- a/pkg/compiler/lib/src/ssa/interceptor_finalizer.dart
+++ b/pkg/compiler/lib/src/ssa/interceptor_finalizer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../constants/values.dart';
import '../elements/entities.dart';
import '../inferrer/abstract_value_domain.dart';
diff --git a/pkg/compiler/lib/src/ssa/interceptor_simplifier.dart b/pkg/compiler/lib/src/ssa/interceptor_simplifier.dart
index c474639..030d794 100644
--- a/pkg/compiler/lib/src/ssa/interceptor_simplifier.dart
+++ b/pkg/compiler/lib/src/ssa/interceptor_simplifier.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common/elements.dart' show CommonElements;
import '../constants/values.dart';
import '../elements/entities.dart';
diff --git a/pkg/compiler/lib/src/ssa/invoke_dynamic_specializers.dart b/pkg/compiler/lib/src/ssa/invoke_dynamic_specializers.dart
index f514f5f..5e55d7e 100644
--- a/pkg/compiler/lib/src/ssa/invoke_dynamic_specializers.dart
+++ b/pkg/compiler/lib/src/ssa/invoke_dynamic_specializers.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common/elements.dart' show JCommonElements;
import '../constants/constant_system.dart' as constant_system;
import '../constants/values.dart';
diff --git a/pkg/compiler/lib/src/ssa/jump_handler.dart b/pkg/compiler/lib/src/ssa/jump_handler.dart
index ff2911d..f246ab0 100644
--- a/pkg/compiler/lib/src/ssa/jump_handler.dart
+++ b/pkg/compiler/lib/src/ssa/jump_handler.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common.dart';
import '../elements/jumps.dart';
import '../inferrer/abstract_value_domain.dart';
diff --git a/pkg/compiler/lib/src/ssa/kernel_string_builder.dart b/pkg/compiler/lib/src/ssa/kernel_string_builder.dart
index c21bc69..6e5c643 100644
--- a/pkg/compiler/lib/src/ssa/kernel_string_builder.dart
+++ b/pkg/compiler/lib/src/ssa/kernel_string_builder.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/ssa/locals_handler.dart b/pkg/compiler/lib/src/ssa/locals_handler.dart
index 2452f1a..62bbe2b 100644
--- a/pkg/compiler/lib/src/ssa/locals_handler.dart
+++ b/pkg/compiler/lib/src/ssa/locals_handler.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:compiler/src/js_model/element_map.dart';
import '../closure.dart';
diff --git a/pkg/compiler/lib/src/ssa/logging.dart b/pkg/compiler/lib/src/ssa/logging.dart
index fcbb3ab..2fe3f6f 100644
--- a/pkg/compiler/lib/src/ssa/logging.dart
+++ b/pkg/compiler/lib/src/ssa/logging.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../elements/entities.dart';
import '../elements/types.dart';
import 'package:_fe_analyzer_shared/src/testing/features.dart';
diff --git a/pkg/compiler/lib/src/ssa/loop_handler.dart b/pkg/compiler/lib/src/ssa/loop_handler.dart
index 73e96e9..6b68e63 100644
--- a/pkg/compiler/lib/src/ssa/loop_handler.dart
+++ b/pkg/compiler/lib/src/ssa/loop_handler.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
import '../closure.dart' show CapturedLoopScope;
diff --git a/pkg/compiler/lib/src/ssa/nodes.dart b/pkg/compiler/lib/src/ssa/nodes.dart
index 2026528..1eb9226 100644
--- a/pkg/compiler/lib/src/ssa/nodes.dart
+++ b/pkg/compiler/lib/src/ssa/nodes.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:front_end/src/api_unstable/dart2js.dart' show Link;
import '../closure.dart';
diff --git a/pkg/compiler/lib/src/ssa/optimize.dart b/pkg/compiler/lib/src/ssa/optimize.dart
index 5e178c2..8f3875d 100644
--- a/pkg/compiler/lib/src/ssa/optimize.dart
+++ b/pkg/compiler/lib/src/ssa/optimize.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common.dart';
import '../common/codegen.dart' show CodegenRegistry;
import '../common/elements.dart' show JCommonElements;
diff --git a/pkg/compiler/lib/src/ssa/ssa.dart b/pkg/compiler/lib/src/ssa/ssa.dart
index 40243ad..5468735 100644
--- a/pkg/compiler/lib/src/ssa/ssa.dart
+++ b/pkg/compiler/lib/src/ssa/ssa.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library ssa;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/ssa/ssa_branch_builder.dart b/pkg/compiler/lib/src/ssa/ssa_branch_builder.dart
index df4e293..a3b5095 100644
--- a/pkg/compiler/lib/src/ssa/ssa_branch_builder.dart
+++ b/pkg/compiler/lib/src/ssa/ssa_branch_builder.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common.dart';
import '../inferrer/abstract_value_domain.dart';
import '../io/source_information.dart';
diff --git a/pkg/compiler/lib/src/ssa/ssa_tracer.dart b/pkg/compiler/lib/src/ssa/ssa_tracer.dart
index 231e4a3..a47bd34 100644
--- a/pkg/compiler/lib/src/ssa/ssa_tracer.dart
+++ b/pkg/compiler/lib/src/ssa/ssa_tracer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library ssa.tracer;
import '../../compiler.dart' show OutputSink;
diff --git a/pkg/compiler/lib/src/ssa/switch_continue_analysis.dart b/pkg/compiler/lib/src/ssa/switch_continue_analysis.dart
index bf99220..5f58be1 100644
--- a/pkg/compiler/lib/src/ssa/switch_continue_analysis.dart
+++ b/pkg/compiler/lib/src/ssa/switch_continue_analysis.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:kernel/ast.dart' as ir;
/// Helper class that traverses a kernel AST subtree to see if it has any
diff --git a/pkg/compiler/lib/src/ssa/type_builder.dart b/pkg/compiler/lib/src/ssa/type_builder.dart
index e7e0a25..a70a154 100644
--- a/pkg/compiler/lib/src/ssa/type_builder.dart
+++ b/pkg/compiler/lib/src/ssa/type_builder.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'builder_kernel.dart';
import 'nodes.dart';
import '../elements/entities.dart';
diff --git a/pkg/compiler/lib/src/ssa/types.dart b/pkg/compiler/lib/src/ssa/types.dart
index 64e4c28..afcca37 100644
--- a/pkg/compiler/lib/src/ssa/types.dart
+++ b/pkg/compiler/lib/src/ssa/types.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common/elements.dart' show CommonElements;
import '../elements/entities.dart';
import '../elements/types.dart';
diff --git a/pkg/compiler/lib/src/ssa/types_propagation.dart b/pkg/compiler/lib/src/ssa/types_propagation.dart
index 5a88ac3..082183b 100644
--- a/pkg/compiler/lib/src/ssa/types_propagation.dart
+++ b/pkg/compiler/lib/src/ssa/types_propagation.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common/elements.dart' show CommonElements;
import '../elements/entities.dart';
import '../elements/types.dart';
diff --git a/pkg/compiler/lib/src/ssa/validate.dart b/pkg/compiler/lib/src/ssa/validate.dart
index 04c7f00..8659468 100644
--- a/pkg/compiler/lib/src/ssa/validate.dart
+++ b/pkg/compiler/lib/src/ssa/validate.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'nodes.dart';
class HValidator extends HInstructionVisitor {
diff --git a/pkg/compiler/lib/src/ssa/value_range_analyzer.dart b/pkg/compiler/lib/src/ssa/value_range_analyzer.dart
index d84928d..ffdb466 100644
--- a/pkg/compiler/lib/src/ssa/value_range_analyzer.dart
+++ b/pkg/compiler/lib/src/ssa/value_range_analyzer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../constants/constant_system.dart' as constant_system;
import '../constants/values.dart';
import '../world.dart' show JClosedWorld;
diff --git a/pkg/compiler/lib/src/ssa/value_set.dart b/pkg/compiler/lib/src/ssa/value_set.dart
index db348c4..3a65307 100644
--- a/pkg/compiler/lib/src/ssa/value_set.dart
+++ b/pkg/compiler/lib/src/ssa/value_set.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../universe/side_effects.dart' show SideEffects;
import 'nodes.dart';
diff --git a/pkg/compiler/lib/src/ssa/variable_allocator.dart b/pkg/compiler/lib/src/ssa/variable_allocator.dart
index 6fa6dbd..8bde9c7 100644
--- a/pkg/compiler/lib/src/ssa/variable_allocator.dart
+++ b/pkg/compiler/lib/src/ssa/variable_allocator.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common.dart';
import '../js_backend/namer.dart' show ModularNamer;
import 'codegen.dart' show CodegenPhase;
diff --git a/pkg/compiler/lib/src/tracer.dart b/pkg/compiler/lib/src/tracer.dart
index 4e03751..9ecb938 100644
--- a/pkg/compiler/lib/src/tracer.dart
+++ b/pkg/compiler/lib/src/tracer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library tracer;
import 'package:kernel/text/indentation.dart' show Indentation;
diff --git a/pkg/compiler/lib/src/universe/call_structure.dart b/pkg/compiler/lib/src/universe/call_structure.dart
index 0062fc9..e421377 100644
--- a/pkg/compiler/lib/src/universe/call_structure.dart
+++ b/pkg/compiler/lib/src/universe/call_structure.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.call_structure;
import '../common/names.dart' show Names;
diff --git a/pkg/compiler/lib/src/universe/class_hierarchy.dart b/pkg/compiler/lib/src/universe/class_hierarchy.dart
index a2e6d01..edaba36 100644
--- a/pkg/compiler/lib/src/universe/class_hierarchy.dart
+++ b/pkg/compiler/lib/src/universe/class_hierarchy.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common.dart';
import '../common/elements.dart';
import '../elements/entities.dart';
diff --git a/pkg/compiler/lib/src/universe/class_set.dart b/pkg/compiler/lib/src/universe/class_set.dart
index f7c899d..b538a40 100644
--- a/pkg/compiler/lib/src/universe/class_set.dart
+++ b/pkg/compiler/lib/src/universe/class_set.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.world.class_set;
import 'dart:collection' show IterableBase, MapBase;
diff --git a/pkg/compiler/lib/src/universe/codegen_world_builder.dart b/pkg/compiler/lib/src/universe/codegen_world_builder.dart
index 1832cbc..710e2c4 100644
--- a/pkg/compiler/lib/src/universe/codegen_world_builder.dart
+++ b/pkg/compiler/lib/src/universe/codegen_world_builder.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:collection';
import '../common.dart';
diff --git a/pkg/compiler/lib/src/universe/feature.dart b/pkg/compiler/lib/src/universe/feature.dart
index 8358202..213c7bf 100644
--- a/pkg/compiler/lib/src/universe/feature.dart
+++ b/pkg/compiler/lib/src/universe/feature.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// TODO(sigmund): rename universe => world
/// Describes individual features that may be seen in a program. Most features
/// can be described only by name using the [Feature] enum, some features are
diff --git a/pkg/compiler/lib/src/universe/function_set.dart b/pkg/compiler/lib/src/universe/function_set.dart
index 6661fc9..13f48fc 100644
--- a/pkg/compiler/lib/src/universe/function_set.dart
+++ b/pkg/compiler/lib/src/universe/function_set.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library universe.function_set;
import '../common/names.dart' show Identifiers, Selectors;
diff --git a/pkg/compiler/lib/src/universe/member_usage.dart b/pkg/compiler/lib/src/universe/member_usage.dart
index f3fe0b1..2356b7a 100644
--- a/pkg/compiler/lib/src/universe/member_usage.dart
+++ b/pkg/compiler/lib/src/universe/member_usage.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:math' as Math;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/universe/resolution_world_builder.dart b/pkg/compiler/lib/src/universe/resolution_world_builder.dart
index 3f31e7b..c545b07 100644
--- a/pkg/compiler/lib/src/universe/resolution_world_builder.dart
+++ b/pkg/compiler/lib/src/universe/resolution_world_builder.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../common.dart';
import '../common/elements.dart';
import '../common/names.dart' show Identifiers, Names;
diff --git a/pkg/compiler/lib/src/universe/selector.dart b/pkg/compiler/lib/src/universe/selector.dart
index 8ea7244..757c6c2 100644
--- a/pkg/compiler/lib/src/universe/selector.dart
+++ b/pkg/compiler/lib/src/universe/selector.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.selector;
import '../common.dart';
diff --git a/pkg/compiler/lib/src/universe/side_effects.dart b/pkg/compiler/lib/src/universe/side_effects.dart
index 4e8bab0..a8cf6a2 100644
--- a/pkg/compiler/lib/src/universe/side_effects.dart
+++ b/pkg/compiler/lib/src/universe/side_effects.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library universe.side_effects;
import '../elements/entities.dart';
diff --git a/pkg/compiler/lib/src/universe/target_checks.dart b/pkg/compiler/lib/src/universe/target_checks.dart
index 6d4ac79..11416d8 100644
--- a/pkg/compiler/lib/src/universe/target_checks.dart
+++ b/pkg/compiler/lib/src/universe/target_checks.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.target_checks;
/// A summary of the checks required when entering a target method.
diff --git a/pkg/compiler/lib/src/universe/use.dart b/pkg/compiler/lib/src/universe/use.dart
index cffa3fc..2d7159a 100644
--- a/pkg/compiler/lib/src/universe/use.dart
+++ b/pkg/compiler/lib/src/universe/use.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// This library defines individual world impacts.
///
/// We call these building blocks `uses`. Each `use` is a single impact of the
diff --git a/pkg/compiler/lib/src/universe/world_builder.dart b/pkg/compiler/lib/src/universe/world_builder.dart
index d75a9e2..bb364e2 100644
--- a/pkg/compiler/lib/src/universe/world_builder.dart
+++ b/pkg/compiler/lib/src/universe/world_builder.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library world_builder;
import '../common/elements.dart';
diff --git a/pkg/compiler/lib/src/universe/world_impact.dart b/pkg/compiler/lib/src/universe/world_impact.dart
index acd7038..a4a4c43 100644
--- a/pkg/compiler/lib/src/universe/world_impact.dart
+++ b/pkg/compiler/lib/src/universe/world_impact.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.universe.world_impact;
import '../elements/entities.dart';
diff --git a/pkg/compiler/lib/src/util/sink_adapter.dart b/pkg/compiler/lib/src/util/sink_adapter.dart
index 1b093a4..da29d86 100644
--- a/pkg/compiler/lib/src/util/sink_adapter.dart
+++ b/pkg/compiler/lib/src/util/sink_adapter.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import '../../compiler.dart' as api;
class BinaryOutputSinkAdapter implements Sink<List<int>> {
diff --git a/pkg/compiler/lib/src/world.dart b/pkg/compiler/lib/src/world.dart
index 7a77d72..276eee7 100644
--- a/pkg/compiler/lib/src/world.dart
+++ b/pkg/compiler/lib/src/world.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.world;
import 'closure.dart';
diff --git a/pkg/compiler/test/codegen/data/shift_right_unsigned.dart b/pkg/compiler/test/codegen/data/shift_right_unsigned.dart
index 521f9d3..f22ff46 100644
--- a/pkg/compiler/test/codegen/data/shift_right_unsigned.dart
+++ b/pkg/compiler/test/codegen/data/shift_right_unsigned.dart
@@ -2,7 +2,7 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
-//@dart=2.14
+// @dart = 2.14
/*member: main:ignore*/
void main() {
diff --git a/pkg/compiler/test/codegen/data/tdiv1.dart b/pkg/compiler/test/codegen/data/tdiv1.dart
index fe6e9f6..bea45a8 100644
--- a/pkg/compiler/test/codegen/data/tdiv1.dart
+++ b/pkg/compiler/test/codegen/data/tdiv1.dart
@@ -2,7 +2,7 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
-//@dart=2.12
+// @dart = 2.12
/*member: main:ignore*/
void main() {
diff --git a/pkg/compiler/test/codegen/data_2/unused_empty_map.dart b/pkg/compiler/test/codegen/data_2/unused_empty_map.dart
index 0ac9666..565217b 100644
--- a/pkg/compiler/test/codegen/data_2/unused_empty_map.dart
+++ b/pkg/compiler/test/codegen/data_2/unused_empty_map.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// ignore_for_file: unused_local_variable
@pragma('dart2js:noInline')
diff --git a/pkg/compiler/test/codegen/late_test.dart b/pkg/compiler/test/codegen/late_test.dart
index 0810efd..af820fb 100644
--- a/pkg/compiler/test/codegen/late_test.dart
+++ b/pkg/compiler/test/codegen/late_test.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:async';
import 'package:async_helper/async_helper.dart';
import '../helpers/compiler_helper.dart';
diff --git a/pkg/compiler/test/custom_split/data/diamond/constraints.dart b/pkg/compiler/test/custom_split/data/diamond/constraints.dart
index 88ccb84..8f3679d 100644
--- a/pkg/compiler/test/custom_split/data/diamond/constraints.dart
+++ b/pkg/compiler/test/custom_split/data/diamond/constraints.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:isolate';
import 'package:compiler/src/deferred_load/program_split_constraints/nodes.dart';
diff --git a/pkg/compiler/test/custom_split/data/diamond/main.dart b/pkg/compiler/test/custom_split/data/diamond/main.dart
index 910949d..c17dfa5 100644
--- a/pkg/compiler/test/custom_split/data/diamond/main.dart
+++ b/pkg/compiler/test/custom_split/data/diamond/main.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/*library:
a_pre_fragments=[
p1: {units: [5{step3}], usedBy: [], needs: []},
diff --git a/pkg/compiler/test/custom_split/data/diamond/shared.dart b/pkg/compiler/test/custom_split/data/diamond/shared.dart
index 716a9ac..1428242 100644
--- a/pkg/compiler/test/custom_split/data/diamond/shared.dart
+++ b/pkg/compiler/test/custom_split/data/diamond/shared.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
@pragma('dart2js:noInline')
/*member: step12a:member_unit=1{step1, step2a, step2b, step3}*/
step12a() => '12a';
diff --git a/pkg/compiler/test/custom_split/data/diamond/step1.dart b/pkg/compiler/test/custom_split/data/diamond/step1.dart
index d87a15b..c067494 100644
--- a/pkg/compiler/test/custom_split/data/diamond/step1.dart
+++ b/pkg/compiler/test/custom_split/data/diamond/step1.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=1{step1, step2a, step2b, step3}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond/step2a.dart b/pkg/compiler/test/custom_split/data/diamond/step2a.dart
index e5f2dce..0c3c7d9 100644
--- a/pkg/compiler/test/custom_split/data/diamond/step2a.dart
+++ b/pkg/compiler/test/custom_split/data/diamond/step2a.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=2{step2a, step3}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond/step2b.dart b/pkg/compiler/test/custom_split/data/diamond/step2b.dart
index e733005..3fd2ba7 100644
--- a/pkg/compiler/test/custom_split/data/diamond/step2b.dart
+++ b/pkg/compiler/test/custom_split/data/diamond/step2b.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=4{step2b, step3}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond/step3.dart b/pkg/compiler/test/custom_split/data/diamond/step3.dart
index 05cc4af..d10a09f 100644
--- a/pkg/compiler/test/custom_split/data/diamond/step3.dart
+++ b/pkg/compiler/test/custom_split/data/diamond/step3.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=5{step3}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond_and/constraints.dart b/pkg/compiler/test/custom_split/data/diamond_and/constraints.dart
index a333016..25fc111 100644
--- a/pkg/compiler/test/custom_split/data/diamond_and/constraints.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_and/constraints.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:isolate';
import 'package:compiler/src/deferred_load/program_split_constraints/nodes.dart';
diff --git a/pkg/compiler/test/custom_split/data/diamond_and/main.dart b/pkg/compiler/test/custom_split/data/diamond_and/main.dart
index 910949d..c17dfa5 100644
--- a/pkg/compiler/test/custom_split/data/diamond_and/main.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_and/main.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/*library:
a_pre_fragments=[
p1: {units: [5{step3}], usedBy: [], needs: []},
diff --git a/pkg/compiler/test/custom_split/data/diamond_and/shared.dart b/pkg/compiler/test/custom_split/data/diamond_and/shared.dart
index 716a9ac..1428242 100644
--- a/pkg/compiler/test/custom_split/data/diamond_and/shared.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_and/shared.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
@pragma('dart2js:noInline')
/*member: step12a:member_unit=1{step1, step2a, step2b, step3}*/
step12a() => '12a';
diff --git a/pkg/compiler/test/custom_split/data/diamond_and/step1.dart b/pkg/compiler/test/custom_split/data/diamond_and/step1.dart
index d87a15b..c067494 100644
--- a/pkg/compiler/test/custom_split/data/diamond_and/step1.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_and/step1.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=1{step1, step2a, step2b, step3}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond_and/step2a.dart b/pkg/compiler/test/custom_split/data/diamond_and/step2a.dart
index e5f2dce..0c3c7d9 100644
--- a/pkg/compiler/test/custom_split/data/diamond_and/step2a.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_and/step2a.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=2{step2a, step3}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond_and/step2b.dart b/pkg/compiler/test/custom_split/data/diamond_and/step2b.dart
index e733005..3fd2ba7 100644
--- a/pkg/compiler/test/custom_split/data/diamond_and/step2b.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_and/step2b.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=4{step2b, step3}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond_and/step3.dart b/pkg/compiler/test/custom_split/data/diamond_and/step3.dart
index 05cc4af..d10a09f 100644
--- a/pkg/compiler/test/custom_split/data/diamond_and/step3.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_and/step3.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=5{step3}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond_fuse/constraints.dart b/pkg/compiler/test/custom_split/data/diamond_fuse/constraints.dart
index a0fe64f..785f51f 100644
--- a/pkg/compiler/test/custom_split/data/diamond_fuse/constraints.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_fuse/constraints.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:isolate';
import 'package:compiler/src/deferred_load/program_split_constraints/nodes.dart';
diff --git a/pkg/compiler/test/custom_split/data/diamond_fuse/main.dart b/pkg/compiler/test/custom_split/data/diamond_fuse/main.dart
index 1067c37..223a406 100644
--- a/pkg/compiler/test/custom_split/data/diamond_fuse/main.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_fuse/main.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/*library:
a_pre_fragments=[
p1: {units: [3{step3}], usedBy: [], needs: []},
diff --git a/pkg/compiler/test/custom_split/data/diamond_fuse/shared.dart b/pkg/compiler/test/custom_split/data/diamond_fuse/shared.dart
index 102c8ae1..d923121 100644
--- a/pkg/compiler/test/custom_split/data/diamond_fuse/shared.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_fuse/shared.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
@pragma('dart2js:noInline')
/*member: step12a:member_unit=1{step1, step2a, step2b, step3}*/
step12a() => '12a';
diff --git a/pkg/compiler/test/custom_split/data/diamond_fuse/step1.dart b/pkg/compiler/test/custom_split/data/diamond_fuse/step1.dart
index d87a15b..c067494 100644
--- a/pkg/compiler/test/custom_split/data/diamond_fuse/step1.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_fuse/step1.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=1{step1, step2a, step2b, step3}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond_fuse/step2a.dart b/pkg/compiler/test/custom_split/data/diamond_fuse/step2a.dart
index c669534..5fbb310 100644
--- a/pkg/compiler/test/custom_split/data/diamond_fuse/step2a.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_fuse/step2a.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=2{step2a, step2b, step3}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond_fuse/step2b.dart b/pkg/compiler/test/custom_split/data/diamond_fuse/step2b.dart
index d543265..1a117ac 100644
--- a/pkg/compiler/test/custom_split/data/diamond_fuse/step2b.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_fuse/step2b.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=2{step2a, step2b, step3}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond_fuse/step3.dart b/pkg/compiler/test/custom_split/data/diamond_fuse/step3.dart
index f924158..dd75638 100644
--- a/pkg/compiler/test/custom_split/data/diamond_fuse/step3.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_fuse/step3.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=3{step3}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond_or/constraints.dart b/pkg/compiler/test/custom_split/data/diamond_or/constraints.dart
index bdc5e1f..e7bba4a 100644
--- a/pkg/compiler/test/custom_split/data/diamond_or/constraints.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_or/constraints.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:isolate';
import 'package:compiler/src/deferred_load/program_split_constraints/nodes.dart';
diff --git a/pkg/compiler/test/custom_split/data/diamond_or/main.dart b/pkg/compiler/test/custom_split/data/diamond_or/main.dart
index eeac09b..cba0dbb 100644
--- a/pkg/compiler/test/custom_split/data/diamond_or/main.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_or/main.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/*library:
a_pre_fragments=[
p1: {units: [2{step2a}], usedBy: [], needs: []},
diff --git a/pkg/compiler/test/custom_split/data/diamond_or/shared.dart b/pkg/compiler/test/custom_split/data/diamond_or/shared.dart
index 60cec94..99c8df3 100644
--- a/pkg/compiler/test/custom_split/data/diamond_or/shared.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_or/shared.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
@pragma('dart2js:noInline')
/*member: step12a:member_unit=1{step1, step2a, step2b, step3}*/
step12a() => '12a';
diff --git a/pkg/compiler/test/custom_split/data/diamond_or/step1.dart b/pkg/compiler/test/custom_split/data/diamond_or/step1.dart
index d87a15b..c067494 100644
--- a/pkg/compiler/test/custom_split/data/diamond_or/step1.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_or/step1.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=1{step1, step2a, step2b, step3}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond_or/step2a.dart b/pkg/compiler/test/custom_split/data/diamond_or/step2a.dart
index 6c52220..838f870 100644
--- a/pkg/compiler/test/custom_split/data/diamond_or/step2a.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_or/step2a.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=2{step2a}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond_or/step2b.dart b/pkg/compiler/test/custom_split/data/diamond_or/step2b.dart
index 46e7aca..a6bca12 100644
--- a/pkg/compiler/test/custom_split/data/diamond_or/step2b.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_or/step2b.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=5{step2b}*/
diff --git a/pkg/compiler/test/custom_split/data/diamond_or/step3.dart b/pkg/compiler/test/custom_split/data/diamond_or/step3.dart
index c4d45a9..14698e4 100644
--- a/pkg/compiler/test/custom_split/data/diamond_or/step3.dart
+++ b/pkg/compiler/test/custom_split/data/diamond_or/step3.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=7{step3}*/
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_and/constraints.dart b/pkg/compiler/test/custom_split/data/fuse_with_and/constraints.dart
index 12a80ee..717a0be 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_and/constraints.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_and/constraints.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:isolate';
import 'package:compiler/src/deferred_load/program_split_constraints/nodes.dart';
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_and/lib1.dart b/pkg/compiler/test/custom_split/data/fuse_with_and/lib1.dart
index 33e2c05..0c19a44 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_and/lib1.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_and/lib1.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import 'lib_100_0.dart' deferred as b1;
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_and/lib2.dart b/pkg/compiler/test/custom_split/data/fuse_with_and/lib2.dart
index 1ad0cd3..31f3fb5 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_and/lib2.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_and/lib2.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import 'lib_010_0.dart' deferred as b2;
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_and/lib3.dart b/pkg/compiler/test/custom_split/data/fuse_with_and/lib3.dart
index 1d2b9d5..f4c371c 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_and/lib3.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_and/lib3.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import 'lib_001_0.dart' deferred as b3;
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_and/lib4.dart b/pkg/compiler/test/custom_split/data/fuse_with_and/lib4.dart
index 1eedd87..a7745aa 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_and/lib4.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_and/lib4.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import 'lib_000_1.dart' deferred as b4;
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_and/libImport.dart b/pkg/compiler/test/custom_split/data/fuse_with_and/libImport.dart
index d55f632..1600ef5 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_and/libImport.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_and/libImport.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_and/lib_000_1.dart b/pkg/compiler/test/custom_split/data/fuse_with_and/lib_000_1.dart
index 091a013..77d098a 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_and/lib_000_1.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_and/lib_000_1.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_and/lib_001_0.dart b/pkg/compiler/test/custom_split/data/fuse_with_and/lib_001_0.dart
index 19906dd..065a929 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_and/lib_001_0.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_and/lib_001_0.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_and/lib_010_0.dart b/pkg/compiler/test/custom_split/data/fuse_with_and/lib_010_0.dart
index 22b05ac..6806187 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_and/lib_010_0.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_and/lib_010_0.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_and/lib_100_0.dart b/pkg/compiler/test/custom_split/data/fuse_with_and/lib_100_0.dart
index d39141b..64becce 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_and/lib_100_0.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_and/lib_100_0.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_and/main.dart b/pkg/compiler/test/custom_split/data/fuse_with_and/main.dart
index f07ccf9..50f7f0b 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_and/main.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_and/main.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/*library:
a_pre_fragments=[
p1: {units: [2{b4}], usedBy: [], needs: []},
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_or/constraints.dart b/pkg/compiler/test/custom_split/data/fuse_with_or/constraints.dart
index 370ca10..38822d6 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_or/constraints.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_or/constraints.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:isolate';
import 'package:compiler/src/deferred_load/program_split_constraints/nodes.dart';
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_or/lib1.dart b/pkg/compiler/test/custom_split/data/fuse_with_or/lib1.dart
index 33e2c05..0c19a44 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_or/lib1.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_or/lib1.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import 'lib_100_0.dart' deferred as b1;
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_or/lib2.dart b/pkg/compiler/test/custom_split/data/fuse_with_or/lib2.dart
index 1ad0cd3..31f3fb5 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_or/lib2.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_or/lib2.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import 'lib_010_0.dart' deferred as b2;
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_or/lib3.dart b/pkg/compiler/test/custom_split/data/fuse_with_or/lib3.dart
index 1d2b9d5..f4c371c 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_or/lib3.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_or/lib3.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import 'lib_001_0.dart' deferred as b3;
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_or/lib4.dart b/pkg/compiler/test/custom_split/data/fuse_with_or/lib4.dart
index 1eedd87..a7745aa 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_or/lib4.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_or/lib4.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import 'lib_000_1.dart' deferred as b4;
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_or/libImport.dart b/pkg/compiler/test/custom_split/data/fuse_with_or/libImport.dart
index dd4364a..5817718 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_or/libImport.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_or/libImport.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_or/lib_000_1.dart b/pkg/compiler/test/custom_split/data/fuse_with_or/lib_000_1.dart
index 5407d70..a4198f7 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_or/lib_000_1.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_or/lib_000_1.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_or/lib_001_0.dart b/pkg/compiler/test/custom_split/data/fuse_with_or/lib_001_0.dart
index 1614e60..e63a03c 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_or/lib_001_0.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_or/lib_001_0.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_or/lib_010_0.dart b/pkg/compiler/test/custom_split/data/fuse_with_or/lib_010_0.dart
index 4cf27c5..3a6a5f4 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_or/lib_010_0.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_or/lib_010_0.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_or/lib_100_0.dart b/pkg/compiler/test/custom_split/data/fuse_with_or/lib_100_0.dart
index 0fe7274..725a10b 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_or/lib_100_0.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_or/lib_100_0.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/fuse_with_or/main.dart b/pkg/compiler/test/custom_split/data/fuse_with_or/main.dart
index a2531cb..2040bfa 100644
--- a/pkg/compiler/test/custom_split/data/fuse_with_or/main.dart
+++ b/pkg/compiler/test/custom_split/data/fuse_with_or/main.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/*library:
a_pre_fragments=[
p1: {units: [6{b4}], usedBy: [], needs: []},
diff --git a/pkg/compiler/test/custom_split/data/just_fuse/constraints.dart b/pkg/compiler/test/custom_split/data/just_fuse/constraints.dart
index 3b4280a..dfce626 100644
--- a/pkg/compiler/test/custom_split/data/just_fuse/constraints.dart
+++ b/pkg/compiler/test/custom_split/data/just_fuse/constraints.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:isolate';
import 'package:compiler/src/deferred_load/program_split_constraints/nodes.dart';
diff --git a/pkg/compiler/test/custom_split/data/just_fuse/lib1.dart b/pkg/compiler/test/custom_split/data/just_fuse/lib1.dart
index 33e2c05..0c19a44 100644
--- a/pkg/compiler/test/custom_split/data/just_fuse/lib1.dart
+++ b/pkg/compiler/test/custom_split/data/just_fuse/lib1.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import 'lib_100_0.dart' deferred as b1;
diff --git a/pkg/compiler/test/custom_split/data/just_fuse/lib2.dart b/pkg/compiler/test/custom_split/data/just_fuse/lib2.dart
index 1ad0cd3..31f3fb5 100644
--- a/pkg/compiler/test/custom_split/data/just_fuse/lib2.dart
+++ b/pkg/compiler/test/custom_split/data/just_fuse/lib2.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import 'lib_010_0.dart' deferred as b2;
diff --git a/pkg/compiler/test/custom_split/data/just_fuse/lib3.dart b/pkg/compiler/test/custom_split/data/just_fuse/lib3.dart
index 1d2b9d5..f4c371c 100644
--- a/pkg/compiler/test/custom_split/data/just_fuse/lib3.dart
+++ b/pkg/compiler/test/custom_split/data/just_fuse/lib3.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import 'lib_001_0.dart' deferred as b3;
diff --git a/pkg/compiler/test/custom_split/data/just_fuse/lib4.dart b/pkg/compiler/test/custom_split/data/just_fuse/lib4.dart
index 1eedd87..a7745aa 100644
--- a/pkg/compiler/test/custom_split/data/just_fuse/lib4.dart
+++ b/pkg/compiler/test/custom_split/data/just_fuse/lib4.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import 'lib_000_1.dart' deferred as b4;
diff --git a/pkg/compiler/test/custom_split/data/just_fuse/libImport.dart b/pkg/compiler/test/custom_split/data/just_fuse/libImport.dart
index 1f64eba..0a54258 100644
--- a/pkg/compiler/test/custom_split/data/just_fuse/libImport.dart
+++ b/pkg/compiler/test/custom_split/data/just_fuse/libImport.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/just_fuse/lib_000_1.dart b/pkg/compiler/test/custom_split/data/just_fuse/lib_000_1.dart
index 189dcd0..ad014bc 100644
--- a/pkg/compiler/test/custom_split/data/just_fuse/lib_000_1.dart
+++ b/pkg/compiler/test/custom_split/data/just_fuse/lib_000_1.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/just_fuse/lib_001_0.dart b/pkg/compiler/test/custom_split/data/just_fuse/lib_001_0.dart
index 9320c80..b72c517 100644
--- a/pkg/compiler/test/custom_split/data/just_fuse/lib_001_0.dart
+++ b/pkg/compiler/test/custom_split/data/just_fuse/lib_001_0.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/just_fuse/lib_010_0.dart b/pkg/compiler/test/custom_split/data/just_fuse/lib_010_0.dart
index b2575c3..49afc5c 100644
--- a/pkg/compiler/test/custom_split/data/just_fuse/lib_010_0.dart
+++ b/pkg/compiler/test/custom_split/data/just_fuse/lib_010_0.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/just_fuse/lib_100_0.dart b/pkg/compiler/test/custom_split/data/just_fuse/lib_100_0.dart
index 4d8ad55..15dfab1 100644
--- a/pkg/compiler/test/custom_split/data/just_fuse/lib_100_0.dart
+++ b/pkg/compiler/test/custom_split/data/just_fuse/lib_100_0.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// This file was autogenerated by the pkg/compiler/tool/graph_isomorphizer.dart.
import "package:expect/expect.dart";
diff --git a/pkg/compiler/test/custom_split/data/just_fuse/main.dart b/pkg/compiler/test/custom_split/data/just_fuse/main.dart
index 7cceec0..895d70c 100644
--- a/pkg/compiler/test/custom_split/data/just_fuse/main.dart
+++ b/pkg/compiler/test/custom_split/data/just_fuse/main.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/*library:
a_pre_fragments=[
p1: {units: [7{b4}], usedBy: [], needs: []},
diff --git a/pkg/compiler/test/custom_split/data/two_branch/constraints.dart b/pkg/compiler/test/custom_split/data/two_branch/constraints.dart
index 27a00ab..2e87d3c 100644
--- a/pkg/compiler/test/custom_split/data/two_branch/constraints.dart
+++ b/pkg/compiler/test/custom_split/data/two_branch/constraints.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:isolate';
import 'package:compiler/src/deferred_load/program_split_constraints/nodes.dart';
diff --git a/pkg/compiler/test/custom_split/data/two_branch/main.dart b/pkg/compiler/test/custom_split/data/two_branch/main.dart
index 84b2505..6025284 100644
--- a/pkg/compiler/test/custom_split/data/two_branch/main.dart
+++ b/pkg/compiler/test/custom_split/data/two_branch/main.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/*library:
a_pre_fragments=[
p1: {units: [2{step2a}], usedBy: [], needs: []},
diff --git a/pkg/compiler/test/custom_split/data/two_branch/shared.dart b/pkg/compiler/test/custom_split/data/two_branch/shared.dart
index 04d26c4..c6e9de1 100644
--- a/pkg/compiler/test/custom_split/data/two_branch/shared.dart
+++ b/pkg/compiler/test/custom_split/data/two_branch/shared.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
@pragma('dart2js:noInline')
/*member: step12a:member_unit=1{step1, step2a, step2b}*/
step12a() => '12a';
diff --git a/pkg/compiler/test/custom_split/data/two_branch/step1.dart b/pkg/compiler/test/custom_split/data/two_branch/step1.dart
index e178701..0759d7b 100644
--- a/pkg/compiler/test/custom_split/data/two_branch/step1.dart
+++ b/pkg/compiler/test/custom_split/data/two_branch/step1.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=1{step1, step2a, step2b}*/
diff --git a/pkg/compiler/test/custom_split/data/two_branch/step2a.dart b/pkg/compiler/test/custom_split/data/two_branch/step2a.dart
index 7b29726..e71ec5e 100644
--- a/pkg/compiler/test/custom_split/data/two_branch/step2a.dart
+++ b/pkg/compiler/test/custom_split/data/two_branch/step2a.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=2{step2a}*/
diff --git a/pkg/compiler/test/custom_split/data/two_branch/step2b.dart b/pkg/compiler/test/custom_split/data/two_branch/step2b.dart
index e9847b6..42a0a09 100644
--- a/pkg/compiler/test/custom_split/data/two_branch/step2b.dart
+++ b/pkg/compiler/test/custom_split/data/two_branch/step2b.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=4{step2b}*/
diff --git a/pkg/compiler/test/custom_split/data/two_step/constraints.dart b/pkg/compiler/test/custom_split/data/two_step/constraints.dart
index fe0d8a5..e521e4a 100644
--- a/pkg/compiler/test/custom_split/data/two_step/constraints.dart
+++ b/pkg/compiler/test/custom_split/data/two_step/constraints.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:isolate';
import 'package:compiler/src/deferred_load/program_split_constraints/nodes.dart';
diff --git a/pkg/compiler/test/custom_split/data/two_step/main.dart b/pkg/compiler/test/custom_split/data/two_step/main.dart
index 4692179..f662e2a 100644
--- a/pkg/compiler/test/custom_split/data/two_step/main.dart
+++ b/pkg/compiler/test/custom_split/data/two_step/main.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/*library:
a_pre_fragments=[
p1: {units: [3{step3}], usedBy: [], needs: []},
diff --git a/pkg/compiler/test/custom_split/data/two_step/shared.dart b/pkg/compiler/test/custom_split/data/two_step/shared.dart
index 2d487df..da6e4da 100644
--- a/pkg/compiler/test/custom_split/data/two_step/shared.dart
+++ b/pkg/compiler/test/custom_split/data/two_step/shared.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
@pragma('dart2js:noInline')
/*member: step12:member_unit=1{step1, step2, step3}*/
step12() => '12';
diff --git a/pkg/compiler/test/custom_split/data/two_step/step1.dart b/pkg/compiler/test/custom_split/data/two_step/step1.dart
index e6377fe..ad3a958 100644
--- a/pkg/compiler/test/custom_split/data/two_step/step1.dart
+++ b/pkg/compiler/test/custom_split/data/two_step/step1.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=1{step1, step2, step3}*/
diff --git a/pkg/compiler/test/custom_split/data/two_step/step2.dart b/pkg/compiler/test/custom_split/data/two_step/step2.dart
index 85baeb5..a2bfa73 100644
--- a/pkg/compiler/test/custom_split/data/two_step/step2.dart
+++ b/pkg/compiler/test/custom_split/data/two_step/step2.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=2{step2, step3}*/
diff --git a/pkg/compiler/test/custom_split/data/two_step/step3.dart b/pkg/compiler/test/custom_split/data/two_step/step3.dart
index 5f84ee6..62124e4 100644
--- a/pkg/compiler/test/custom_split/data/two_step/step3.dart
+++ b/pkg/compiler/test/custom_split/data/two_step/step3.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'shared.dart';
/*member: step:member_unit=3{step3}*/
diff --git a/pkg/compiler/test/deferred_loading/data/components/libA.dart b/pkg/compiler/test/deferred_loading/data/components/libA.dart
index 156d3fc..5fd97f9 100644
--- a/pkg/compiler/test/deferred_loading/data/components/libA.dart
+++ b/pkg/compiler/test/deferred_loading/data/components/libA.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/*member: component:member_unit=1{libA}*/
String component() {
return 'libA';
diff --git a/pkg/compiler/test/deferred_loading/data/components/libB.dart b/pkg/compiler/test/deferred_loading/data/components/libB.dart
index 87b10d5..bd7f786 100644
--- a/pkg/compiler/test/deferred_loading/data/components/libB.dart
+++ b/pkg/compiler/test/deferred_loading/data/components/libB.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import "libBCDE.dart";
/*member: component:member_unit=2{libB}*/
diff --git a/pkg/compiler/test/deferred_loading/data/components/libBCDE.dart b/pkg/compiler/test/deferred_loading/data/components/libBCDE.dart
index 77a74fe..2a8442c 100644
--- a/pkg/compiler/test/deferred_loading/data/components/libBCDE.dart
+++ b/pkg/compiler/test/deferred_loading/data/components/libBCDE.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
@pragma('dart2js:noInline')
/*member: componentBCDE:member_unit=3{libB, libC, libD, libE}*/
String componentBCDE() {
diff --git a/pkg/compiler/test/deferred_loading/data/components/libC.dart b/pkg/compiler/test/deferred_loading/data/components/libC.dart
index d13a2f5..9d598a2 100644
--- a/pkg/compiler/test/deferred_loading/data/components/libC.dart
+++ b/pkg/compiler/test/deferred_loading/data/components/libC.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import "libBCDE.dart";
/*member: component:member_unit=4{libC}*/
diff --git a/pkg/compiler/test/deferred_loading/data/components/libD.dart b/pkg/compiler/test/deferred_loading/data/components/libD.dart
index c20123e..6c27dd2 100644
--- a/pkg/compiler/test/deferred_loading/data/components/libD.dart
+++ b/pkg/compiler/test/deferred_loading/data/components/libD.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import "libBCDE.dart";
/*member: component:member_unit=5{libD}*/
diff --git a/pkg/compiler/test/deferred_loading/data/components/libE.dart b/pkg/compiler/test/deferred_loading/data/components/libE.dart
index fd8e3c2..b0c72ae 100644
--- a/pkg/compiler/test/deferred_loading/data/components/libE.dart
+++ b/pkg/compiler/test/deferred_loading/data/components/libE.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import "libBCDE.dart";
/*member: component:member_unit=6{libE}*/
diff --git a/pkg/compiler/test/deferred_loading/data/many_parts/lib1.dart b/pkg/compiler/test/deferred_loading/data/many_parts/lib1.dart
index ed47af6..07c1c88 100644
--- a/pkg/compiler/test/deferred_loading/data/many_parts/lib1.dart
+++ b/pkg/compiler/test/deferred_loading/data/many_parts/lib1.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'lib_000_01.dart' deferred as b1;
/*member: entryLib1:member_unit=main{}*/
diff --git a/pkg/compiler/test/deferred_loading/data/many_parts/lib2.dart b/pkg/compiler/test/deferred_loading/data/many_parts/lib2.dart
index 6b04665..bc303e8 100644
--- a/pkg/compiler/test/deferred_loading/data/many_parts/lib2.dart
+++ b/pkg/compiler/test/deferred_loading/data/many_parts/lib2.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'lib_000_10.dart' deferred as b2;
/*member: entryLib2:member_unit=main{}*/
diff --git a/pkg/compiler/test/deferred_loading/data/many_parts/lib3.dart b/pkg/compiler/test/deferred_loading/data/many_parts/lib3.dart
index 5c7b1ff..24c38ea 100644
--- a/pkg/compiler/test/deferred_loading/data/many_parts/lib3.dart
+++ b/pkg/compiler/test/deferred_loading/data/many_parts/lib3.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'lib_001_00.dart' deferred as b3;
/*member: entryLib3:member_unit=main{}*/
diff --git a/pkg/compiler/test/deferred_loading/data/many_parts/lib4.dart b/pkg/compiler/test/deferred_loading/data/many_parts/lib4.dart
index 909bac0..f099cf5 100644
--- a/pkg/compiler/test/deferred_loading/data/many_parts/lib4.dart
+++ b/pkg/compiler/test/deferred_loading/data/many_parts/lib4.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'lib_010_00.dart' deferred as b4;
/*member: entryLib4:member_unit=main{}*/
diff --git a/pkg/compiler/test/deferred_loading/data/many_parts/lib5.dart b/pkg/compiler/test/deferred_loading/data/many_parts/lib5.dart
index c5eff23..89af3fd 100644
--- a/pkg/compiler/test/deferred_loading/data/many_parts/lib5.dart
+++ b/pkg/compiler/test/deferred_loading/data/many_parts/lib5.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'lib_100_00.dart' deferred as b5;
/*member: entryLib5:member_unit=main{}*/
diff --git a/pkg/compiler/test/deferred_loading/data/many_parts/libB.dart b/pkg/compiler/test/deferred_loading/data/many_parts/libB.dart
index 8fa7f8e..34539e3 100644
--- a/pkg/compiler/test/deferred_loading/data/many_parts/libB.dart
+++ b/pkg/compiler/test/deferred_loading/data/many_parts/libB.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import "package:expect/expect.dart";
/*member: v:member_unit=2{b1, b2, b3, b4, b5}*/
diff --git a/pkg/compiler/test/deferred_loading/data/many_parts/lib_000_01.dart b/pkg/compiler/test/deferred_loading/data/many_parts/lib_000_01.dart
index bb1e6d9..665ce9a 100644
--- a/pkg/compiler/test/deferred_loading/data/many_parts/lib_000_01.dart
+++ b/pkg/compiler/test/deferred_loading/data/many_parts/lib_000_01.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import "package:expect/expect.dart";
import 'libB.dart';
diff --git a/pkg/compiler/test/deferred_loading/data/many_parts/lib_000_10.dart b/pkg/compiler/test/deferred_loading/data/many_parts/lib_000_10.dart
index c7c8597..2dfe4d7 100644
--- a/pkg/compiler/test/deferred_loading/data/many_parts/lib_000_10.dart
+++ b/pkg/compiler/test/deferred_loading/data/many_parts/lib_000_10.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import "package:expect/expect.dart";
import 'libB.dart';
diff --git a/pkg/compiler/test/deferred_loading/data/many_parts/lib_001_00.dart b/pkg/compiler/test/deferred_loading/data/many_parts/lib_001_00.dart
index 1b86845..0713f39 100644
--- a/pkg/compiler/test/deferred_loading/data/many_parts/lib_001_00.dart
+++ b/pkg/compiler/test/deferred_loading/data/many_parts/lib_001_00.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import "package:expect/expect.dart";
import 'libB.dart';
diff --git a/pkg/compiler/test/deferred_loading/data/many_parts/lib_010_00.dart b/pkg/compiler/test/deferred_loading/data/many_parts/lib_010_00.dart
index f23fc51..302d7aa 100644
--- a/pkg/compiler/test/deferred_loading/data/many_parts/lib_010_00.dart
+++ b/pkg/compiler/test/deferred_loading/data/many_parts/lib_010_00.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import "package:expect/expect.dart";
import 'libB.dart';
diff --git a/pkg/compiler/test/deferred_loading/data/many_parts/lib_100_00.dart b/pkg/compiler/test/deferred_loading/data/many_parts/lib_100_00.dart
index b10def2..42361b4 100644
--- a/pkg/compiler/test/deferred_loading/data/many_parts/lib_100_00.dart
+++ b/pkg/compiler/test/deferred_loading/data/many_parts/lib_100_00.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import "package:expect/expect.dart";
import 'libB.dart';
diff --git a/pkg/compiler/test/deferred_loading/data/many_parts/main.dart b/pkg/compiler/test/deferred_loading/data/many_parts/main.dart
index ab6a217..aa07a8a 100644
--- a/pkg/compiler/test/deferred_loading/data/many_parts/main.dart
+++ b/pkg/compiler/test/deferred_loading/data/many_parts/main.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/*spec.library:
a_pre_fragments=[
p10: {units: [18{b2, b3}], usedBy: [], needs: []},
diff --git a/pkg/compiler/test/deferred_loading/data/shadowed_types/lib_shared.dart b/pkg/compiler/test/deferred_loading/data/shadowed_types/lib_shared.dart
index 09e4bf0..bfccea6 100644
--- a/pkg/compiler/test/deferred_loading/data/shadowed_types/lib_shared.dart
+++ b/pkg/compiler/test/deferred_loading/data/shadowed_types/lib_shared.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/*class: A:
class_unit=1{libb},
type_unit=2{liba, libb}
diff --git a/pkg/compiler/test/deferred_loading/data/shadowed_types/liba.dart b/pkg/compiler/test/deferred_loading/data/shadowed_types/liba.dart
index 4ea6fd2..7169d52 100644
--- a/pkg/compiler/test/deferred_loading/data/shadowed_types/liba.dart
+++ b/pkg/compiler/test/deferred_loading/data/shadowed_types/liba.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'lib_shared.dart';
@pragma('dart2js:noInline')
diff --git a/pkg/compiler/test/deferred_loading/data/shadowed_types/libb.dart b/pkg/compiler/test/deferred_loading/data/shadowed_types/libb.dart
index a5a125c..4515d1a 100644
--- a/pkg/compiler/test/deferred_loading/data/shadowed_types/libb.dart
+++ b/pkg/compiler/test/deferred_loading/data/shadowed_types/libb.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'lib_shared.dart';
@pragma('dart2js:noInline')
diff --git a/pkg/compiler/test/deferred_loading/data/shadowed_types/main.dart b/pkg/compiler/test/deferred_loading/data/shadowed_types/main.dart
index 9c29878..f6e1dd8 100644
--- a/pkg/compiler/test/deferred_loading/data/shadowed_types/main.dart
+++ b/pkg/compiler/test/deferred_loading/data/shadowed_types/main.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/*spec.library:
a_pre_fragments=[
p1: {units: [3{liba}], usedBy: [], needs: []},
diff --git a/pkg/compiler/test/end_to_end/data/exit_code_helper.dart b/pkg/compiler/test/end_to_end/data/exit_code_helper.dart
index 4ce6da8..25ba850 100644
--- a/pkg/compiler/test/end_to_end/data/exit_code_helper.dart
+++ b/pkg/compiler/test/end_to_end/data/exit_code_helper.dart
@@ -2,4 +2,6 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
void main() {}
diff --git a/pkg/compiler/test/inference/data/assert_initializer.dart b/pkg/compiler/test/inference/data/assert_initializer.dart
index 9daf511..01673b0 100644
--- a/pkg/compiler/test/inference/data/assert_initializer.dart
+++ b/pkg/compiler/test/inference/data/assert_initializer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
class X {
/*member: X.a:Union([exact=JSExtendableArray], [exact=JSString])*/
final dynamic a;
diff --git a/pkg/compiler/test/inference/data/assert_initializer_ea.dart b/pkg/compiler/test/inference/data/assert_initializer_ea.dart
index bf7f4f1..0ad39ed 100644
--- a/pkg/compiler/test/inference/data/assert_initializer_ea.dart
+++ b/pkg/compiler/test/inference/data/assert_initializer_ea.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
class X {
/*member: X.a:[exact=JSString]*/
final dynamic a;
diff --git a/pkg/compiler/test/inference/data/issue48304.dart b/pkg/compiler/test/inference/data/issue48304.dart
index dc77fc3..63a0d8a 100644
--- a/pkg/compiler/test/inference/data/issue48304.dart
+++ b/pkg/compiler/test/inference/data/issue48304.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.15
+
abstract class B {
call<T>();
}
diff --git a/pkg/compiler/test/inference/data/list_js.dart b/pkg/compiler/test/inference/data/list_js.dart
index 9b64060..2d77bfc 100644
--- a/pkg/compiler/test/inference/data/list_js.dart
+++ b/pkg/compiler/test/inference/data/list_js.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// Test effect of NativeBehavior on list tracing.
/// ignore: IMPORT_INTERNAL_LIBRARY
diff --git a/pkg/compiler/test/js/debug_size_estimator.dart b/pkg/compiler/test/js/debug_size_estimator.dart
index 86b528c..b845db9 100644
--- a/pkg/compiler/test/js/debug_size_estimator.dart
+++ b/pkg/compiler/test/js/debug_size_estimator.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:compiler/src/js/size_estimator.dart';
/// This class is supposed to be identical to [SizeEstimator] with the sole
diff --git a/pkg/compiler/test/optimization/data/shift_right_unsigned.dart b/pkg/compiler/test/optimization/data/shift_right_unsigned.dart
index 6a8aaf3..2e24108 100644
--- a/pkg/compiler/test/optimization/data/shift_right_unsigned.dart
+++ b/pkg/compiler/test/optimization/data/shift_right_unsigned.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.14
+
main() {
shru1(1, 1);
shru1(2, 2);
diff --git a/pkg/compiler/test/optimization/data/string_methods.dart b/pkg/compiler/test/optimization/data/string_methods.dart
index c2aabfc..1cee7c3 100644
--- a/pkg/compiler/test/optimization/data/string_methods.dart
+++ b/pkg/compiler/test/optimization/data/string_methods.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// ---- String.substring
/*member: substring1:Specializer=[substring]*/
diff --git a/pkg/compiler/test/rti/data/instantiated_type_literal.dart b/pkg/compiler/test/rti/data/instantiated_type_literal.dart
index 23443cc..bcead7b 100644
--- a/pkg/compiler/test/rti/data/instantiated_type_literal.dart
+++ b/pkg/compiler/test/rti/data/instantiated_type_literal.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.15
+
/*class: A:exp,needsArgs*/
class A<T> {
instanceMethod() => A<T>;
diff --git a/pkg/compiler/test/rti/data/instantiation8.dart b/pkg/compiler/test/rti/data/instantiation8.dart
index 0e57865..18d080e 100644
--- a/pkg/compiler/test/rti/data/instantiation8.dart
+++ b/pkg/compiler/test/rti/data/instantiation8.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
// TODO(47054): Take closure signature into account to handle equality of
// instantiated closures.
/*class: Class:deps=[create]*/
diff --git a/pkg/compiler/test/rti/data/issue48304.dart b/pkg/compiler/test/rti/data/issue48304.dart
index dfb51be..8eb6621 100644
--- a/pkg/compiler/test/rti/data/issue48304.dart
+++ b/pkg/compiler/test/rti/data/issue48304.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.15
+
/*spec.class: B:explicit=[B]*/
abstract class B {
call<T>();
diff --git a/pkg/compiler/test/rti/emission/instantiated_type_literal.dart b/pkg/compiler/test/rti/emission/instantiated_type_literal.dart
index 5e4cee2..5984daa 100644
--- a/pkg/compiler/test/rti/emission/instantiated_type_literal.dart
+++ b/pkg/compiler/test/rti/emission/instantiated_type_literal.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.15
+
import 'package:compiler/src/util/testing.dart';
/*class: A:checks=[],instance*/
diff --git a/pkg/compiler/test/tool/graph_isomorphizer/graph_isomorphizer_test.dart b/pkg/compiler/test/tool/graph_isomorphizer/graph_isomorphizer_test.dart
index dad02c9..cfae9dd 100644
--- a/pkg/compiler/test/tool/graph_isomorphizer/graph_isomorphizer_test.dart
+++ b/pkg/compiler/test/tool/graph_isomorphizer/graph_isomorphizer_test.dart
@@ -2,7 +2,7 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
-// @dart = 2.
+// @dart = 2.10
import 'dart:io';
diff --git a/pkg/compiler/tool/dart2js_profile_many.dart b/pkg/compiler/tool/dart2js_profile_many.dart
index 9b3d1c2..cc1f47e 100644
--- a/pkg/compiler/tool/dart2js_profile_many.dart
+++ b/pkg/compiler/tool/dart2js_profile_many.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.profile_many;
import 'dart:async';
diff --git a/pkg/compiler/tool/dart2js_stress.dart b/pkg/compiler/tool/dart2js_stress.dart
index 3a458e9..57da831 100644
--- a/pkg/compiler/tool/dart2js_stress.dart
+++ b/pkg/compiler/tool/dart2js_stress.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
library dart2js.stress;
import 'package:compiler/src/dart2js.dart' as dart2js;
diff --git a/pkg/compiler/tool/graph_isomorphizer.dart b/pkg/compiler/tool/graph_isomorphizer.dart
index 74489b8..9859c61 100644
--- a/pkg/compiler/tool/graph_isomorphizer.dart
+++ b/pkg/compiler/tool/graph_isomorphizer.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// This tool builds a program with a deferred graph isomorphic to the provided
/// graph, or generates permutations of bits and the associated files to
/// generate complex deferred graphs.
diff --git a/pkg/compiler/tool/kernel_visitor/dart_html_metrics_visitor.dart b/pkg/compiler/tool/kernel_visitor/dart_html_metrics_visitor.dart
index 79b8b41..72edb13 100644
--- a/pkg/compiler/tool/kernel_visitor/dart_html_metrics_visitor.dart
+++ b/pkg/compiler/tool/kernel_visitor/dart_html_metrics_visitor.dart
@@ -1,6 +1,9 @@
// Copyright (c) 2021, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+
+// @dart = 2.10
+
import "dart:convert";
import "dart:io";
import "package:kernel/kernel.dart";
diff --git a/pkg/compiler/tool/kernel_visitor/test/info_visitor_test.dart b/pkg/compiler/tool/kernel_visitor/test/info_visitor_test.dart
index 885ecb4..3d4d007 100644
--- a/pkg/compiler/tool/kernel_visitor/test/info_visitor_test.dart
+++ b/pkg/compiler/tool/kernel_visitor/test/info_visitor_test.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import "dart:io";
import "package:expect/expect.dart";
diff --git a/pkg/compiler/tool/kernel_visitor/test/test_classes.dart b/pkg/compiler/tool/kernel_visitor/test/test_classes.dart
index 2b02ef8..666d5ae 100644
--- a/pkg/compiler/tool/kernel_visitor/test/test_classes.dart
+++ b/pkg/compiler/tool/kernel_visitor/test/test_classes.dart
@@ -1,6 +1,9 @@
// Copyright (c) 2021, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+
+// @dart = 2.10
+
library info_visitor_test_classes;
// Test superclass value.
diff --git a/pkg/compiler/tool/modular_dart2js.dart b/pkg/compiler/tool/modular_dart2js.dart
index e0f4771..36f2906 100644
--- a/pkg/compiler/tool/modular_dart2js.dart
+++ b/pkg/compiler/tool/modular_dart2js.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'dart:convert';
import 'dart:io';
import 'package:compiler/src/commandline_options.dart';
diff --git a/pkg/compiler/tool/modular_test_suite.dart b/pkg/compiler/tool/modular_test_suite.dart
index 5730ad6..491d6ad 100644
--- a/pkg/compiler/tool/modular_test_suite.dart
+++ b/pkg/compiler/tool/modular_test_suite.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Test the modular compilation pipeline of dart2js.
///
/// This is a shell that runs multiple tests, one per folder under `data/`.
diff --git a/pkg/compiler/tool/modular_test_suite_helper.dart b/pkg/compiler/tool/modular_test_suite_helper.dart
index 7398c3d..b85aeb5 100644
--- a/pkg/compiler/tool/modular_test_suite_helper.dart
+++ b/pkg/compiler/tool/modular_test_suite_helper.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Test the modular compilation pipeline of dart2js.
///
/// This is a shell that runs multiple tests, one per folder under `data/`.
diff --git a/pkg/compiler/tool/modular_test_suite_legacy.dart b/pkg/compiler/tool/modular_test_suite_legacy.dart
index f170069..1f570f9 100644
--- a/pkg/compiler/tool/modular_test_suite_legacy.dart
+++ b/pkg/compiler/tool/modular_test_suite_legacy.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// Test the modular compilation pipeline of dart2js.
///
/// This is a shell that runs multiple tests, one per folder under `data/`.
diff --git a/pkg/compiler/tool/track_memory.dart b/pkg/compiler/tool/track_memory.dart
index a07d3e9..f6b324b 100644
--- a/pkg/compiler/tool/track_memory.dart
+++ b/pkg/compiler/tool/track_memory.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
/// A script to track the high water-mark of memory usage of an application.
/// To monitor how much memory dart2js is using, run dart2js as follows:
///
diff --git a/pkg/compiler/tool/update_id_tests.dart b/pkg/compiler/tool/update_id_tests.dart
index ba805bc..2203b5d 100644
--- a/pkg/compiler/tool/update_id_tests.dart
+++ b/pkg/compiler/tool/update_id_tests.dart
@@ -2,6 +2,8 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+// @dart = 2.10
+
import 'package:_fe_analyzer_shared/src/testing/id_testing.dart' as id;
const List<String> idTests = <String>[
diff --git a/runtime/bin/BUILD.gn b/runtime/bin/BUILD.gn
index 7f0bd21..2877fb3 100644
--- a/runtime/bin/BUILD.gn
+++ b/runtime/bin/BUILD.gn
@@ -604,9 +604,7 @@
args += [ "--executable" ]
}
- if (current_cpu == "x64") {
- args += [ "--64-bit" ]
- }
+ args += [ "--arch=$current_cpu" ]
inputs = [ invoker.input ]
outputs = [ output ]
}
diff --git a/runtime/tools/bin_to_coff.py b/runtime/tools/bin_to_coff.py
index f98f051f..b75521ad 100644
--- a/runtime/tools/bin_to_coff.py
+++ b/runtime/tools/bin_to_coff.py
@@ -32,8 +32,14 @@
# } FILHDR;
FILE_HEADER_FORMAT = 'HHIIIHH'
FILE_HEADER_SIZE = calcsize(FILE_HEADER_FORMAT)
-FILE_HEADER_MAGIC_X64 = 0x8664
-FILE_HEADER_MAGIC_IA32 = 0x014c
+FILE_HEADER_MAGICS = {
+ 'x86': 0x014c,
+ 'x64': 0x8664,
+ 'arm': 0x1c0,
+ 'arm64': 0xaa64,
+ 'riscv32': 0x5032,
+ 'riscv64': 0x5064,
+}
FILE_HEADER_NUM_SECTIONS = 1
FILE_HEADER_TIMESTAMP = 0
FILE_HEADER_SIZE_OF_OPTIONAL = 0
@@ -112,12 +118,12 @@
'--size_symbol_name',
dest='size_name',
help='Name of the symbol for the size of the binary data')
- parser.add_argument(
- '--64-bit', dest='use_64_bit', action='store_true', default=False)
+ parser.add_argument('--arch', dest='arch')
parser.add_argument(
'--executable', dest='executable', action='store_true', default=False)
args = parser.parse_args()
+ use_64_bit = args.arch in ['x64', 'arm64', 'riscv64']
with open(args.input, 'rb') as f:
section_data = f.read()
@@ -130,7 +136,7 @@
includes_size_name = (args.size_name != None)
# Symbols on x86 are prefixed with '_'
- symbol_prefix = b'' if args.use_64_bit else b'_'
+ symbol_prefix = b'_' if args.arch == 'x86' else b''
num_symbols = 2 if includes_size_name else 1
symbol_name = symbol_prefix + args.symbol_name.encode()
size_symbol_name = None
@@ -138,8 +144,8 @@
size_symbol = args.size_name if args.size_name else args.symbol_name + "Size"
size_symbol_name = symbol_prefix + size_symbol.encode()
- size_symbol_format = SIZE_SYMBOL_FORMAT_X64 if args.use_64_bit else SIZE_FORMAT
- size_symbol_size = SIZE_SYMBOL_LENGTH_X64 if args.use_64_bit else SIZE_LENGTH
+ size_symbol_format = SIZE_SYMBOL_FORMAT_X64 if use_64_bit else SIZE_FORMAT
+ size_symbol_size = SIZE_SYMBOL_LENGTH_X64 if use_64_bit else SIZE_LENGTH
# The symbol table is directly after the data section
symbol_table_ptr = (FILE_HEADER_SIZE + SECTION_HEADER_SIZE + section_size +
@@ -166,7 +172,7 @@
num_symbols * SYMBOL_TABLE_ENTRY_SIZE + SIZE_LENGTH + size_symbol_size +
string_table_len)
- FILE_HEADER_MAGIC = FILE_HEADER_MAGIC_X64 if args.use_64_bit else FILE_HEADER_MAGIC_IA32
+ FILE_HEADER_MAGIC = FILE_HEADER_MAGICS[args.arch]
# Populate the file header. Basically constant except for the pointer to the
# beginning of the symbol table.
diff --git a/sdk/lib/html/dart2js/html_dart2js.dart b/sdk/lib/html/dart2js/html_dart2js.dart
index 8ad4a99..671f68a 100644
--- a/sdk/lib/html/dart2js/html_dart2js.dart
+++ b/sdk/lib/html/dart2js/html_dart2js.dart
@@ -26985,6 +26985,15 @@
const EventStreamProvider<MediaStreamEvent>('addstream');
/**
+ * Static factory designed to expose `connectionstatechange` events to event
+ * handlers that are not necessarily instances of [RtcPeerConnection].
+ *
+ * See [EventStreamProvider] for usage information.
+ */
+ static const EventStreamProvider<Event> connectionStateChangeEvent =
+ const EventStreamProvider<Event>('connectionstatechange');
+
+ /**
* Static factory designed to expose `datachannel` events to event
* handlers that are not necessarily instances of [RtcPeerConnection].
*
@@ -27048,6 +27057,8 @@
static const EventStreamProvider<RtcTrackEvent> trackEvent =
const EventStreamProvider<RtcTrackEvent>('track');
+ String? get connectionState native;
+
String? get iceConnectionState native;
String? get iceGatheringState native;
@@ -27162,6 +27173,10 @@
/// Stream of `addstream` events handled by this [RtcPeerConnection].
Stream<MediaStreamEvent> get onAddStream => addStreamEvent.forTarget(this);
+ /// Stream of `connectionstatechange` events handled by this [RtcPeerConnection].
+ Stream<Event> get onConnectionStateChange =>
+ connectionStateChangeEvent.forTarget(this);
+
/// Stream of `datachannel` events handled by this [RtcPeerConnection].
Stream<RtcDataChannelEvent> get onDataChannel =>
dataChannelEvent.forTarget(this);
diff --git a/tests/lib/html/rtc_test.dart b/tests/lib/html/rtc_test.dart
index 6b3c3581..88dc43f 100644
--- a/tests/lib/html/rtc_test.dart
+++ b/tests/lib/html/rtc_test.dart
@@ -41,6 +41,20 @@
new RtcSessionDescription({'sdp': 'foo', 'type': 'offer'});
expect(description is RtcSessionDescription, isTrue);
});
+
+ test('connection state', () {
+ var pc = new RtcPeerConnection({
+ 'iceServers': [
+ {'url': 'stun:216.93.246.18:3478'}
+ ]
+ });
+ // `connectionState` is unsupported on some browsers, so we check
+ // whether the attribute exists first.
+ if (pc.connectionState != null) {
+ expect(pc.connectionState, equals('new'));
+ }
+ pc.onConnectionStateChange.listen((event) {});
+ });
}
});
}
diff --git a/tests/lib_2/html/rtc_test.dart b/tests/lib_2/html/rtc_test.dart
index 1e68cbe..7deffb9 100644
--- a/tests/lib_2/html/rtc_test.dart
+++ b/tests/lib_2/html/rtc_test.dart
@@ -43,6 +43,20 @@
new RtcSessionDescription({'sdp': 'foo', 'type': 'offer'});
expect(description is RtcSessionDescription, isTrue);
});
+
+ test('connection state', () {
+ var pc = new RtcPeerConnection({
+ 'iceServers': [
+ {'url': 'stun:216.93.246.18:3478'}
+ ]
+ });
+ // `connectionState` is unsupported on some browsers, so we check
+ // whether the attribute exists first.
+ if (pc.connectionState != null) {
+ expect(pc.connectionState, equals('new'));
+ }
+ pc.onConnectionStateChange.listen((event) {});
+ });
}
});
}
diff --git a/tools/VERSION b/tools/VERSION
index 6233344..e10152e 100644
--- a/tools/VERSION
+++ b/tools/VERSION
@@ -27,5 +27,5 @@
MAJOR 2
MINOR 17
PATCH 0
-PRERELEASE 277
+PRERELEASE 278
PRERELEASE_PATCH 0
\ No newline at end of file
diff --git a/tools/dom/docs.json b/tools/dom/docs.json
index 2dfd29c..51334c0 100644
--- a/tools/dom/docs.json
+++ b/tools/dom/docs.json
@@ -2834,9 +2834,20 @@
" * See [EventStreamProvider] for usage information.",
" */"
],
+ "connectionstatechangeEvent": [
+ "/**",
+ " * Static factory designed to expose `connectionstatechange` events to event",
+ " * handlers that are not necessarily instances of [RtcPeerConnection].",
+ " *",
+ " * See [EventStreamProvider] for usage information.",
+ " */"
+ ],
"onaddstream": [
"/// Stream of `addstream` events handled by this [RtcPeerConnection]."
],
+ "onconnectionstatechange": [
+ "/// Stream of `connectionstatechange` events handled by this [RtcPeerConnection]."
+ ],
"ondatachannel": [
"/// Stream of `datachannel` events handled by this [RtcPeerConnection]."
],
diff --git a/tools/dom/dom.json b/tools/dom/dom.json
index ebd5826..295e137 100644
--- a/tools/dom/dom.json
+++ b/tools/dom/dom.json
@@ -16409,6 +16409,9 @@
"support_level": "untriaged"
},
"close": {},
+ "connectionState": {
+ "support_level": "untriaged"
+ },
"createAnswer": {},
"createDTMFSender": {},
"createDataChannel": {},
@@ -16437,6 +16440,9 @@
"iceGatheringState": {},
"localDescription": {},
"onaddstream": {},
+ "onconnectionstatechange": {
+ "support_level": "untriaged"
+ },
"ondatachannel": {},
"onicecandidate": {},
"oniceconnectionstatechange": {},
diff --git a/tools/dom/idl/dart/dart.idl b/tools/dom/idl/dart/dart.idl
index f877c25..0021d66 100644
--- a/tools/dom/idl/dart/dart.idl
+++ b/tools/dom/idl/dart/dart.idl
@@ -138,6 +138,8 @@
[DartSuppress] Promise<void> getStats(RTCStatsCallback successCallback, optional MediaStreamTrack? selector);
[DartSuppress] Promise<void> setLocalDescription(RTCSessionDescriptionInit description, VoidCallback successCallback, [Default=Undefined] optional RTCPeerConnectionErrorCallback failureCallback);
[DartSuppress] Promise<void> setRemoteDescription(RTCSessionDescriptionInit description, VoidCallback successCallback, [Default=Undefined] optional RTCPeerConnectionErrorCallback failureCallback);
+ [Custom] readonly attribute DOMString connectionState;
+ [Custom] attribute EventHandler onconnectionstatechange;
};
// See implementation in tools/dom/templates for canvas and offscreenCanvas.
diff --git a/tools/dom/scripts/htmleventgenerator.py b/tools/dom/scripts/htmleventgenerator.py
index d614e88..0e47653 100644
--- a/tools/dom/scripts/htmleventgenerator.py
+++ b/tools/dom/scripts/htmleventgenerator.py
@@ -202,6 +202,8 @@
'RTCDataChannel.open': ('open', 'Event'),
'RTCPeerConnection.addstream': ('addStream', 'MediaStreamEvent'),
'RTCPeerConnection.datachannel': ('dataChannel', 'RtcDataChannelEvent'),
+ 'RTCPeerConnection.connectionstatechange':
+ ('connectionStateChange', 'Event'),
'RTCPeerConnection.icecandidate':
('iceCandidate', 'RtcPeerConnectionIceEvent'),
'RTCPeerConnection.iceconnectionstatechange':