Version 2.0.0-dev.65.0
Merge commit '12971f37a982f42c3e65e51dde4bfb9bc866f7aa' into dev
diff --git a/.packages b/.packages
index 5e2e043..e09d3e7 100644
--- a/.packages
+++ b/.packages
@@ -35,7 +35,6 @@
dartdoc:third_party/pkg/dartdoc/lib
dev_compiler:pkg/dev_compiler/lib
expect:pkg/expect/lib
-fasta:pkg/fasta/lib
fixnum:third_party/pkg/fixnum/lib
front_end:pkg/front_end/lib
func:third_party/pkg/func/lib
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 8c27cf3..723a2e4 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,18 @@
+## 2.0.0-dev.65.0
+
+### Tool Changes
+
+#### dartfmt
+
+ * Add `--fix` to remove unneeded `new` and `const` keywords, and change `:`
+ to `=` before named parameter default values.
+ * Change formatting rules around static methods to uniformly format code with
+ and without `new` and `const`.
+
+#### Pub
+
+ * Pub no longer supports running with `DART_VM_OPTIONS=--no-preview-dart2`.
+
## 2.0.0-dev.64.1
### Language
diff --git a/DEPS b/DEPS
index c1107d7..e7712ec 100644
--- a/DEPS
+++ b/DEPS
@@ -61,7 +61,7 @@
"cli_util_tag" : "0.1.2+1",
"collection_tag": "1.14.10",
"convert_tag": "2.0.1",
- "crypto_tag" : "2.0.2+1",
+ "crypto_tag" : "2.0.5",
"csslib_tag" : "0.14.1",
"dart2js_info_tag" : "0.5.6+4",
@@ -77,9 +77,9 @@
# minutes later.
#
# For more details, see https://github.com/dart-lang/sdk/issues/30164
- "dart_style_tag": "1.0.14", # Please see the note above before updating.
+ "dart_style_tag": "1.1.0", # Please see the note above before updating.
- "dartdoc_tag" : "v0.20.0",
+ "dartdoc_tag" : "v0.20.1",
"fixnum_tag": "0.10.5",
"func_rev": "25eec48146a58967d75330075ab376b3838b18a8",
"glob_tag": "1.1.5",
@@ -102,7 +102,7 @@
"mockito_tag": "d39ac507483b9891165e422ec98d9fb480037c8b",
"mustache4dart_tag" : "v2.1.2",
"oauth2_tag": "1.1.0",
- "observatory_pub_packages_rev": "d3a3aebefbd35aa30fe7bbc2889b772b398f7d7f",
+ "observatory_pub_packages_rev": "caf0aecfb15077fc7a34d48e9df13606c793fddf",
"package_config_tag": "1.0.3",
"package_resolver_tag": "1.0.2+1",
"path_tag": "1.5.1",
@@ -110,9 +110,9 @@
"ply_rev": "604b32590ffad5cbb82e4afef1d305512d06ae93",
"pool_tag": "1.3.4",
"protobuf_tag": "0.7.1",
- "pub_rev": "c84ffa0265fe746824aa6f382cb6c41abc406d42",
+ "pub_rev": "2258022cb7fd6ec43900d3b88012efb268020019",
"pub_semver_tag": "1.4.1",
- "quiver_tag": "5aaa3f58c48608af5b027444d561270b53f15dbf",
+ "quiver_tag": "0.29.0",
"resource_rev":"af5a5bf65511943398146cf146e466e5f0b95cb9",
"root_certificates_rev": "16ef64be64c7dfdff2b9f4b910726e635ccc519e",
"shelf_static_rev": "v0.2.7",
diff --git a/build/dart/dart_action.gni b/build/dart/dart_action.gni
index 77a0130..91f5e293 100644
--- a/build/dart/dart_action.gni
+++ b/build/dart/dart_action.gni
@@ -144,6 +144,11 @@
"--packages=" + rebase_path(invoker.packages),
]
}
+ if (defined(invoker.dfe)) {
+ args += [
+ "--dfe=" + rebase_path(invoker.dfe),
+ ]
+ }
if (defined(invoker.script)) {
args += [ rebase_path(invoker.script) ]
}
@@ -219,9 +224,12 @@
forward_variables_from(invoker, "*")
if (_is_fuchsia) {
binary = prebuilt_dart
+ dfe = "$prebuilt_dart_sdk/bin/snapshots/kernel-service.dart.snapshot"
} else {
binary =
"$_dart_root/tools/sdks/$host_os/dart-sdk/bin/dart$executable_suffix"
+ dfe =
+ "$_dart_root/tools/sdks/$host_os/dart-sdk/bin/snapshots/kernel-service.dart.snapshot"
}
target = "$_dart_root/runtime/bin:dart_bootstrap"
}
diff --git a/docs/language/dartLangSpec.tex b/docs/language/dartLangSpec.tex
index 9ab7861..bad2ba0 100644
--- a/docs/language/dartLangSpec.tex
+++ b/docs/language/dartLangSpec.tex
@@ -3989,10 +3989,12 @@
.
{\bf stringContentTDQ:}\~{}( `$\backslash$' $|$ `{\escapegrammar \texttt{"""}}' $|$ `\$');
+ `$\backslash$' \~{}( NEWLINE );
stringInterpolation
.
{\bf stringContentTSQ:}\~{}( `$\backslash$' $|$ `{\escapegrammar \code{'}\code{'}\code{'}}' $|$ `\$');
+ `$\backslash$' \~{}( NEWLINE );
stringInterpolation
.
@@ -5697,12 +5699,15 @@
\end{grammar}
\LMHash{}
-Evaluation of a cascaded method invocation expression $e$ of the form \code{$e$..\metavar{suffix}} proceeds as follows:
+Evaluation of a cascaded method invocation expression $c$ of the form \code{$e$..\metavar{suffix}} proceeds as follows:
Evaluate $e$ to an object $o$.
Let $t$ be a fresh variable bound to $o$.
Evaluate \code{$t$.\metavar{suffix}} to an object.
-Then $e$ evaluates to $o$.
+Then $c$ evaluates to $o$.
+
+\LMHash{}
+The static type of $c$ is the static type of $e$.
\rationale{
With the introduction of null-aware conditional assignable expressions (\ref{assignableExpressions}), it would make sense to extend cascades with a null-aware conditional form as well.
diff --git a/pkg/analysis_server/test/integration/analysis/error_test.dart b/pkg/analysis_server/test/integration/analysis/error_test.dart
index f7974b4..ad440e8 100644
--- a/pkg/analysis_server/test/integration/analysis/error_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/error_test.dart
@@ -107,19 +107,11 @@
@override
@failingTest
- test_detect_simple_error() {
- return super.test_detect_simple_error();
- }
-
- @override
- @failingTest
test_super_mixins_disabled() {
- // Disabling super mixins is not supported in the new FE.
return super.test_super_mixins_disabled();
}
@override
- @failingTest
test_super_mixins_enabled() {
return super.test_super_mixins_enabled();
}
diff --git a/pkg/analysis_server/test/integration/analysis/get_errors_test.dart b/pkg/analysis_server/test/integration/analysis/get_errors_test.dart
index 981e904..a4912ac 100644
--- a/pkg/analysis_server/test/integration/analysis/get_errors_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/get_errors_test.dart
@@ -40,10 +40,4 @@
class GetErrorsTest_UseCFE extends GetErrorsTest {
@override
bool get useCFE => true;
-
- @failingTest
- @override
- test_getErrors() {
- return super.test_getErrors();
- }
}
diff --git a/pkg/analysis_server/test/integration/analysis/get_imported_elements_test.dart b/pkg/analysis_server/test/integration/analysis/get_imported_elements_test.dart
index 7a10b8a..655fa65 100644
--- a/pkg/analysis_server/test/integration/analysis/get_imported_elements_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/get_imported_elements_test.dart
@@ -145,16 +145,4 @@
extends AnalysisGetImportedElementsIntegrationTest {
@override
bool get useCFE => true;
-
- @failingTest
- @override
- test_getImportedElements_none() {
- return super.test_getImportedElements_none();
- }
-
- @failingTest
- @override
- test_getImportedElements_some() {
- return super.test_getImportedElements_some();
- }
}
diff --git a/pkg/analysis_server/test/integration/analysis/get_navigation_test.dart b/pkg/analysis_server/test/integration/analysis/get_navigation_test.dart
index 96995ae..667c92e 100644
--- a/pkg/analysis_server/test/integration/analysis/get_navigation_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/get_navigation_test.dart
@@ -79,6 +79,6 @@
@override
@failingTest
test_navigation_no_result() {
- fail('This test crashes with CFE');
+ fail('Test fails with CFE');
}
}
diff --git a/pkg/analysis_server/test/integration/analysis/lint_test.dart b/pkg/analysis_server/test/integration/analysis/lint_test.dart
index ae9649d..d217042 100644
--- a/pkg/analysis_server/test/integration/analysis/lint_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/lint_test.dart
@@ -87,22 +87,4 @@
class LintIntegrationTest_UseCFE extends LintIntegrationTest {
@override
bool get useCFE => true;
-
- @override
- @failingTest
- test_no_lints_when_not_specified() {
- return super.test_no_lints_when_not_specified();
- }
-
- @override
- @failingTest
- test_simple_lint_newOptionsFile() {
- return super.test_simple_lint_newOptionsFile();
- }
-
- @override
- @failingTest
- test_simple_lint_oldOptionsFile() {
- return super.test_simple_lint_oldOptionsFile();
- }
}
diff --git a/pkg/analysis_server/test/integration/analysis/occurrences_test.dart b/pkg/analysis_server/test/integration/analysis/occurrences_test.dart
index eeda63a..5174ef4 100644
--- a/pkg/analysis_server/test/integration/analysis/occurrences_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/occurrences_test.dart
@@ -71,10 +71,4 @@
class OccurrencesTest_UseCFE extends OccurrencesTest {
@override
bool get useCFE => true;
-
- @failingTest
- @override
- test_occurrences() {
- return super.test_occurrences();
- }
}
diff --git a/pkg/analysis_server/test/integration/analysis/outline_test.dart b/pkg/analysis_server/test/integration/analysis/outline_test.dart
index 6192813..5a4a07f 100644
--- a/pkg/analysis_server/test/integration/analysis/outline_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/outline_test.dart
@@ -75,10 +75,4 @@
class OutlineTest_UseCFE extends OutlineTest {
@override
bool get useCFE => true;
-
- @failingTest
- @override
- test_outline() {
- return super.test_outline();
- }
}
diff --git a/pkg/analysis_server/test/integration/analysis/overrides_test.dart b/pkg/analysis_server/test/integration/analysis/overrides_test.dart
index 2cfb696..eebfc59 100644
--- a/pkg/analysis_server/test/integration/analysis/overrides_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/overrides_test.dart
@@ -127,9 +127,6 @@
@override
bool get useCFE => true;
- @failingTest
@override
- test_overrides() {
- return super.test_overrides();
- }
+ test_overrides() => super.test_overrides();
}
diff --git a/pkg/analysis_server/test/integration/analysis/package_root_test.dart b/pkg/analysis_server/test/integration/analysis/package_root_test.dart
index 08c2d8d..5cca2f0 100644
--- a/pkg/analysis_server/test/integration/analysis/package_root_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/package_root_test.dart
@@ -83,10 +83,4 @@
class SetAnalysisRootsTest_UseCFE extends SetAnalysisRootsTest {
@override
bool get useCFE => true;
-
- @override
- @failingTest
- test_package_root() {
- return super.test_package_root();
- }
}
diff --git a/pkg/analysis_server/test/integration/analysis/reanalyze_concurrent_test.dart b/pkg/analysis_server/test/integration/analysis/reanalyze_concurrent_test.dart
index 0cb0424..ac80f32 100644
--- a/pkg/analysis_server/test/integration/analysis/reanalyze_concurrent_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/reanalyze_concurrent_test.dart
@@ -59,6 +59,6 @@
@failingTest
@override
test_reanalyze_concurrent() {
- fail('This test crashes under the CFE');
+ fail('Test fails with CFE');
}
}
diff --git a/pkg/analysis_server/test/integration/analysis/reanalyze_test.dart b/pkg/analysis_server/test/integration/analysis/reanalyze_test.dart
index 27a4c81..44e1830 100644
--- a/pkg/analysis_server/test/integration/analysis/reanalyze_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/reanalyze_test.dart
@@ -48,6 +48,6 @@
@failingTest
@override
test_reanalyze() {
- fail('This test crashes under the CFE');
+ fail('Test fails with CFE');
}
}
diff --git a/pkg/analysis_server/test/integration/analysis/set_analysis_roots_test.dart b/pkg/analysis_server/test/integration/analysis/set_analysis_roots_test.dart
index dfbbe69..f9ebcb0 100644
--- a/pkg/analysis_server/test/integration/analysis/set_analysis_roots_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/set_analysis_roots_test.dart
@@ -36,10 +36,4 @@
class SetAnalysisRootsTest_UseCFE extends SetAnalysisRootsTest {
@override
bool get useCFE => true;
-
- @failingTest
- @override
- test_options() {
- return super.test_options();
- }
}
diff --git a/pkg/analysis_server/test/integration/analysis/set_general_subscriptions_test.dart b/pkg/analysis_server/test/integration/analysis/set_general_subscriptions_test.dart
index bbd07a0..1a0920e 100644
--- a/pkg/analysis_server/test/integration/analysis/set_general_subscriptions_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/set_general_subscriptions_test.dart
@@ -50,6 +50,6 @@
@failingTest
@override
test_options() {
- fail('This test crashes under the CFE');
+ fail('Test fails with CFE');
}
}
diff --git a/pkg/analysis_server/test/integration/analysis/set_priority_files_test.dart b/pkg/analysis_server/test/integration/analysis/set_priority_files_test.dart
index 64aeb6d..439f5aa 100644
--- a/pkg/analysis_server/test/integration/analysis/set_priority_files_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/set_priority_files_test.dart
@@ -38,6 +38,6 @@
@failingTest
@override
test_options() {
- fail('This test crashes under the CFE');
+ fail('Test fails with CFE');
}
}
diff --git a/pkg/analysis_server/test/integration/analysis/set_subscriptions_test.dart b/pkg/analysis_server/test/integration/analysis/set_subscriptions_test.dart
index c1fcead..02dcd05 100644
--- a/pkg/analysis_server/test/integration/analysis/set_subscriptions_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/set_subscriptions_test.dart
@@ -36,10 +36,4 @@
class SetSubscriptionsTest_UseCFE extends SetSubscriptionsTest {
@override
bool get useCFE => true;
-
- @failingTest
- @override
- test_subscriptions() {
- return super.test_subscriptions();
- }
}
diff --git a/pkg/analysis_server/test/integration/analysis/update_content_list_test.dart b/pkg/analysis_server/test/integration/analysis/update_content_list_test.dart
index 42ef868..e1bf7d7 100644
--- a/pkg/analysis_server/test/integration/analysis/update_content_list_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/update_content_list_test.dart
@@ -60,7 +60,7 @@
@override
@failingTest
test_updateContent_list() {
- // TODO(devoncarew): Class '_CompileTimeError' not found in library 'dart:core'.
+ // TODO(devoncarew): at character offset 2550: Bad state: Data already stored for offset -1.
return super.test_updateContent_list();
}
}
diff --git a/pkg/analysis_server/test/integration/analysis/update_content_test.dart b/pkg/analysis_server/test/integration/analysis/update_content_test.dart
index 2c084a5..8174832 100644
--- a/pkg/analysis_server/test/integration/analysis/update_content_test.dart
+++ b/pkg/analysis_server/test/integration/analysis/update_content_test.dart
@@ -110,16 +110,4 @@
class UpdateContentTest_UseCFE extends UpdateContentTest {
@override
bool get useCFE => true;
-
- @failingTest
- @override
- test_updateContent() {
- return super.test_updateContent();
- }
-
- @failingTest
- @override
- test_updateContent_multipleAdds() {
- return super.test_updateContent_multipleAdds();
- }
}
diff --git a/pkg/analysis_server/test/integration/completion/get_suggestions_test.dart b/pkg/analysis_server/test/integration/completion/get_suggestions_test.dart
index b5087a9..75dad25 100644
--- a/pkg/analysis_server/test/integration/completion/get_suggestions_test.dart
+++ b/pkg/analysis_server/test/integration/completion/get_suggestions_test.dart
@@ -121,22 +121,4 @@
class GetSuggestionsTest_UseCFE extends GetSuggestionsTest {
@override
bool get useCFE => true;
-
- @override
- @failingTest
- test_getSuggestions() {
- return super.test_getSuggestions();
- }
-
- @override
- @failingTest
- test_getSuggestions_onlyOverlay() {
- return super.test_getSuggestions_onlyOverlay();
- }
-
- @override
- @failingTest
- test_getSuggestions_onlyOverlay_noWait() {
- return super.test_getSuggestions_onlyOverlay_noWait();
- }
}
diff --git a/pkg/analysis_server/test/integration/edit/get_available_refactorings_test.dart b/pkg/analysis_server/test/integration/edit/get_available_refactorings_test.dart
index 260ab07..0d359f6 100644
--- a/pkg/analysis_server/test/integration/edit/get_available_refactorings_test.dart
+++ b/pkg/analysis_server/test/integration/edit/get_available_refactorings_test.dart
@@ -41,10 +41,4 @@
class GetAvailableRefactoringsTest_UseCFE extends GetAvailableRefactoringsTest {
@override
bool get useCFE => true;
-
- @failingTest
- @override
- test_has_refactorings() {
- return super.test_has_refactorings();
- }
}
diff --git a/pkg/analysis_server/test/integration/edit/get_fixes_test.dart b/pkg/analysis_server/test/integration/edit/get_fixes_test.dart
index 6fd7413..c0e52b7 100644
--- a/pkg/analysis_server/test/integration/edit/get_fixes_test.dart
+++ b/pkg/analysis_server/test/integration/edit/get_fixes_test.dart
@@ -70,10 +70,4 @@
@override
@failingTest
Future test_has_fixes() => super.test_has_fixes();
-
- @failingTest
- @override
- test_no_fixes() {
- fail('Test crashes with CFE');
- }
}
diff --git a/pkg/analysis_server/test/integration/edit/get_postfix_completion_test.dart b/pkg/analysis_server/test/integration/edit/get_postfix_completion_test.dart
index 7d7faba..8e34a3b 100644
--- a/pkg/analysis_server/test/integration/edit/get_postfix_completion_test.dart
+++ b/pkg/analysis_server/test/integration/edit/get_postfix_completion_test.dart
@@ -56,10 +56,4 @@
class GetPostfixCompletionTest_UseCFE extends GetPostfixCompletionTest {
@override
bool get useCFE => true;
-
- @failingTest
- @override
- test_postfix_completion() {
- return super.test_postfix_completion();
- }
}
diff --git a/pkg/analysis_server/test/integration/edit/import_elements_test.dart b/pkg/analysis_server/test/integration/edit/import_elements_test.dart
index e565a1e..da142fc 100644
--- a/pkg/analysis_server/test/integration/edit/import_elements_test.dart
+++ b/pkg/analysis_server/test/integration/edit/import_elements_test.dart
@@ -144,22 +144,4 @@
extends AnalysisGetImportElementsIntegrationTest {
@override
bool get useCFE => true;
-
- @failingTest
- @override
- test_importElements_definingUnit() {
- return super.test_importElements_definingUnit();
- }
-
- @failingTest
- @override
- test_importElements_noEdits() {
- return super.test_importElements_noEdits();
- }
-
- @failingTest
- @override
- test_importElements_part() {
- return super.test_importElements_part();
- }
}
diff --git a/pkg/analysis_server/test/integration/edit/is_postfix_completion_applicable_test.dart b/pkg/analysis_server/test/integration/edit/is_postfix_completion_applicable_test.dart
index 4dbf569..32f59cb 100644
--- a/pkg/analysis_server/test/integration/edit/is_postfix_completion_applicable_test.dart
+++ b/pkg/analysis_server/test/integration/edit/is_postfix_completion_applicable_test.dart
@@ -46,10 +46,4 @@
extends IsPostfixCompletionApplicableTest {
@override
bool get useCFE => true;
-
- @failingTest
- @override
- test_is_postfix_completion_applicable() {
- return super.test_is_postfix_completion_applicable();
- }
}
diff --git a/pkg/analysis_server/test/integration/edit/list_postfix_completion_templates_test.dart b/pkg/analysis_server/test/integration/edit/list_postfix_completion_templates_test.dart
index a9009c7..3caf5f80 100644
--- a/pkg/analysis_server/test/integration/edit/list_postfix_completion_templates_test.dart
+++ b/pkg/analysis_server/test/integration/edit/list_postfix_completion_templates_test.dart
@@ -46,10 +46,4 @@
extends ListPostfixCompletionTemplatesTest {
@override
bool get useCFE => true;
-
- @failingTest
- @override
- test_list_postfix_completion_templates() {
- fail('Test crashes with CFE');
- }
}
diff --git a/pkg/analysis_server/test/integration/edit/organize_directives_test.dart b/pkg/analysis_server/test/integration/edit/organize_directives_test.dart
index a30d913..4d519e9 100644
--- a/pkg/analysis_server/test/integration/edit/organize_directives_test.dart
+++ b/pkg/analysis_server/test/integration/edit/organize_directives_test.dart
@@ -80,22 +80,4 @@
class OrganizeDirectivesTest_UseCFE extends OrganizeDirectivesTest {
@override
bool get useCFE => true;
-
- @failingTest
- @override
- test_organize_directives() {
- return super.test_organize_directives();
- }
-
- @failingTest
- @override
- test_organize_directives_no_changes() {
- return super.test_organize_directives_no_changes();
- }
-
- @failingTest
- @override
- test_organize_directives_with_errors() {
- return super.test_organize_directives_with_errors();
- }
}
diff --git a/pkg/analysis_server/test/integration/execution/delete_context_test.dart b/pkg/analysis_server/test/integration/execution/delete_context_test.dart
index 07904fd..3cf0e19 100644
--- a/pkg/analysis_server/test/integration/execution/delete_context_test.dart
+++ b/pkg/analysis_server/test/integration/execution/delete_context_test.dart
@@ -47,10 +47,4 @@
class DeleteContextTest_UseCFE extends DeleteContextTest {
@override
bool get useCFE => true;
-
- @override
- @failingTest
- test_delete() {
- fail('Test crashes with CFE');
- }
}
diff --git a/pkg/analysis_server/test/integration/execution/map_uri_test.dart b/pkg/analysis_server/test/integration/execution/map_uri_test.dart
index d0c886c..9990a23 100644
--- a/pkg/analysis_server/test/integration/execution/map_uri_test.dart
+++ b/pkg/analysis_server/test/integration/execution/map_uri_test.dart
@@ -44,10 +44,4 @@
class MapUriTest_UseCFE extends MapUriTest {
@override
bool get useCFE => true;
-
- @override
- @failingTest
- test_mapUri() {
- fail('Test crashes with CFE');
- }
}
diff --git a/pkg/analysis_server/test/integration/kythe/get_kythe_entries_test.dart b/pkg/analysis_server/test/integration/kythe/get_kythe_entries_test.dart
index 234fd49..823ac4d 100644
--- a/pkg/analysis_server/test/integration/kythe/get_kythe_entries_test.dart
+++ b/pkg/analysis_server/test/integration/kythe/get_kythe_entries_test.dart
@@ -43,10 +43,4 @@
class GetKytheEntriesTest_UseCFE extends GetKytheEntriesTest {
@override
bool get useCFE => true;
-
- @override
- @failingTest
- test_getKytheEntries() {
- return super.test_getKytheEntries();
- }
}
diff --git a/pkg/analysis_server/test/integration/search/find_element_references_test.dart b/pkg/analysis_server/test/integration/search/find_element_references_test.dart
index 4f1cdd7..f5cf5a6 100644
--- a/pkg/analysis_server/test/integration/search/find_element_references_test.dart
+++ b/pkg/analysis_server/test/integration/search/find_element_references_test.dart
@@ -79,12 +79,5 @@
@override
@failingTest
- test_badTarget() {
- fail('Test times out with CFE.');
- }
-
- @override
- @failingTest
- // TODO(devoncarew): 'NoSuchMethodError: The getter 'source' was called on null'
- Future test_findReferences() => new Future.error('failing test');
+ Future test_findReferences() => fail('Test fails with CFE');
}
diff --git a/pkg/analysis_server/test/integration/search/find_member_declarations_test.dart b/pkg/analysis_server/test/integration/search/find_member_declarations_test.dart
index bdab78a..38f0c67 100644
--- a/pkg/analysis_server/test/integration/search/find_member_declarations_test.dart
+++ b/pkg/analysis_server/test/integration/search/find_member_declarations_test.dart
@@ -55,10 +55,4 @@
class FindMemberDeclarationsTest_UseCFE extends FindMemberDeclarationsTest {
@override
bool get useCFE => true;
-
- @override
- @failingTest
- test_findMemberDeclarations() {
- fail('Test times out with CFE.');
- }
}
diff --git a/pkg/analysis_server/test/integration/server/status_test.dart b/pkg/analysis_server/test/integration/server/status_test.dart
index 231aa4f..dab8eaa 100644
--- a/pkg/analysis_server/test/integration/server/status_test.dart
+++ b/pkg/analysis_server/test/integration/server/status_test.dart
@@ -54,10 +54,4 @@
class StatusTest_UseCFE extends StatusTest {
@override
bool get useCFE => true;
-
- @override
- @failingTest
- test_status() {
- fail('This test crashes CFE');
- }
}
diff --git a/pkg/analyzer/lib/dart/ast/ast.dart b/pkg/analyzer/lib/dart/ast/ast.dart
index a34bf60..ac71287 100644
--- a/pkg/analyzer/lib/dart/ast/ast.dart
+++ b/pkg/analyzer/lib/dart/ast/ast.dart
@@ -6,7 +6,7 @@
* Defines the AST model. The AST (Abstract Syntax Tree) model describes the
* syntactic (as opposed to semantic) structure of Dart code. The semantic
* structure of the code is modeled by the
- * [element model](../element/element.dart).
+ * [element model](../dart_element_element/dart_element_element-library.html).
*
* An AST consists of nodes (instances of a subclass of [AstNode]). The nodes
* are organized in a tree structure in which the children of a node are the
diff --git a/pkg/analyzer/lib/dart/element/element.dart b/pkg/analyzer/lib/dart/element/element.dart
index 8af9b7d..60afc67 100644
--- a/pkg/analyzer/lib/dart/element/element.dart
+++ b/pkg/analyzer/lib/dart/element/element.dart
@@ -5,11 +5,13 @@
/**
* Defines the element model. The element model describes the semantic (as
* opposed to syntactic) structure of Dart code. The syntactic structure of the
- * code is modeled by the [AST structure](../ast/ast.dart).
+ * code is modeled by the [AST
+ * structure](../analyzer.dart.ast.ast/analyzer.dart.ast.ast-library.html).
*
* The element model consists of two closely related kinds of objects: elements
* (instances of a subclass of [Element]) and types. This library defines the
- * elements, the types are defined in [type.dart](type.dart).
+ * elements, the types are defined in
+ * [type.dart](../dart_element_type/dart_element_type-library.html).
*
* Generally speaking, an element represents something that is declared in the
* code, such as a class, method, or variable. Elements are organized in a tree
diff --git a/pkg/analyzer/lib/dart/element/type.dart b/pkg/analyzer/lib/dart/element/type.dart
index 64c8606..7467480 100644
--- a/pkg/analyzer/lib/dart/element/type.dart
+++ b/pkg/analyzer/lib/dart/element/type.dart
@@ -4,9 +4,10 @@
/**
* Defines the type model. The type model is part of the
- * [element model](element.dart) in that most types are defined by Dart code
- * (the types `dynamic` and `void` being the notable exceptions). All types are
- * represented by an instance of a subclass of [DartType].
+ * [element model](../dart_element_element/dart_element_element-library.html)
+ * in that most types are defined by Dart code (the types `dynamic` and `void`
+ * being the notable exceptions). All types are represented by an instance of a
+ * subclass of [DartType].
*
* Other than `dynamic` and `void`, all of the types define either the interface
* defined by a class (an instance of [InterfaceType]) or the type of a function
diff --git a/pkg/analyzer/lib/error/error.dart b/pkg/analyzer/lib/error/error.dart
index a47d7a0..1557389 100644
--- a/pkg/analyzer/lib/error/error.dart
+++ b/pkg/analyzer/lib/error/error.dart
@@ -129,6 +129,8 @@
CompileTimeErrorCode.FIELD_INITIALIZER_REDIRECTING_CONSTRUCTOR,
CompileTimeErrorCode.FINAL_INITIALIZED_MULTIPLE_TIMES,
CompileTimeErrorCode.GENERIC_FUNCTION_TYPED_PARAM_UNSUPPORTED,
+ CompileTimeErrorCode.GENERIC_FUNCTION_TYPE_CANNOT_BE_BOUND,
+ CompileTimeErrorCode.GENERIC_FUNCTION_CANNOT_BE_TYPE_ARGUMENT,
CompileTimeErrorCode.GETTER_AND_METHOD_WITH_SAME_NAME,
CompileTimeErrorCode.IMPLEMENTS_DEFERRED_CLASS,
CompileTimeErrorCode.IMPLEMENTS_DISALLOWED_CLASS,
diff --git a/pkg/analyzer/lib/src/dart/analysis/frontend_resolution.dart b/pkg/analyzer/lib/src/dart/analysis/frontend_resolution.dart
index a1845c1..03f505c 100644
--- a/pkg/analyzer/lib/src/dart/analysis/frontend_resolution.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/frontend_resolution.dart
@@ -61,13 +61,13 @@
/// The wrapper around FrontEnd compiler that can be used incrementally.
///
/// When the client needs the kernel, resolution information, and errors for
-/// a library, it should call [compile]. The compiler will compile the library
+/// a library, it should call [getResolution]. The compiler will compile the library
/// and the transitive closure of its dependencies. The results are cached,
/// so the next invocation for a dependency will be served from the cache.
///
/// If a file is changed, [invalidate] should be invoked. This will invalidate
/// the file, its library, and the transitive closure of dependencies. So, the
-/// next invocation of [compile] will recompile libraries required for the
+/// next invocation of [getResolution] will recompile libraries required for the
/// requested library.
class FrontEndCompiler {
static const MSG_PENDING_COMPILE =
@@ -88,10 +88,6 @@
/// The listener / recorder for compilation errors produced by the compiler.
final _ErrorListener _errorListener;
- /// Each key is the absolute URI of a library.
- /// Each value is the compilation result of the key library.
- final Map<Uri, LibraryCompilationResult> _results = {};
-
/// The [Component] with currently valid libraries. When a file is invalidated,
/// we remove the file, its library, and everything affected from [_component].
Component _component = new Component();
@@ -108,7 +104,7 @@
/// Each value is the file system URI of the library that sources the part.
final Map<Uri, Uri> _partToLibrary = {};
- /// Whether [compile] is executing.
+ /// Whether [getResolution] is executing.
bool _isCompileExecuting = false;
factory FrontEndCompiler(
@@ -179,38 +175,124 @@
: _logger = _options.logger,
_fileSystem = _options.fileSystem;
- /// Compile the library with the given absolute [uri], and everything it
- /// depends on. Return the result of the requested library compilation.
+ /// Return the outline of the library with the given absolute [uri], and
+ /// everything it depends on.
///
- /// If there is the cached result for the library (compiled directly, or as
- /// a result of compilation of another library), it will be returned quickly.
+ /// If there is the cached outline for the library (computed directly, or as
+ /// a result of computing the outline of another library), it will be
+ /// returned quickly.
///
/// Throw [StateError] if another compilation is pending.
- Future<LibraryCompilationResult> compile(Uri uri) {
+ Future<LibraryOutlineResult> getOutline(Uri uri) {
if (_isCompileExecuting) {
throw new StateError(MSG_PENDING_COMPILE);
}
_isCompileExecuting = true;
- {
- LibraryCompilationResult result = _results[uri];
- if (result != null) {
- _isCompileExecuting = false;
- return new Future.value(result);
- }
+ // TODO(scheglov) Do we need a map?
+ if (_component.root.hasChild('$uri')) {
+ _isCompileExecuting = false;
+ // TODO(scheglov) Can we keep the same instance?
+ var types = new TypeEnvironment(
+ new CoreTypes(_component), new ClassHierarchy(_component));
+ var result = new LibraryOutlineResult(_component, types);
+ return new Future.value(result);
}
- return _runWithFrontEndContext('Compile', () async {
- // TODO(brianwilkerson) Determine whether this await is necessary.
- await null;
+ return _runWithFrontEndContext('Compute outline', () async {
try {
var dillTarget =
new DillTarget(_options.ticker, uriTranslator, _options.target);
// Append all libraries what we still have in the current component.
await _logger.runAsync('Load dill libraries', () async {
- // TODO(brianwilkerson) Determine whether this await is necessary.
- await null;
+ dillTarget.loader.appendLibraries(_component);
+ await dillTarget.buildOutlines();
+ });
+
+ // Create the target for computing the outline of the library.
+ var kernelTarget = new KernelTarget(
+ _fileSystem, true, dillTarget, uriTranslator,
+ metadataCollector: new AnalyzerMetadataCollector());
+ kernelTarget.read(uri);
+
+ // Compute new outlines.
+ var newComponent = await _logger.runAsync('Compile', () async {
+ return await kernelTarget.buildOutlines(nameRoot: _component.root);
+ });
+
+ // Add new libraries to the current component.
+ if (newComponent != null) {
+ // When a file is used in a `part` directive of a library, but does
+ // not have a `part of` itself, we get this file both as a part,
+ // and as a library. This causes an exception later in resolution.
+ var partFileUris = new Set<Uri>();
+ for (var library in newComponent.libraries) {
+ var libraryFileUri = library.fileUri;
+ for (var part in library.parts) {
+ var partFileUri = libraryFileUri.resolve(part.partUri);
+ if (partFileUri != libraryFileUri) {
+ partFileUris.add(partFileUri);
+ }
+ }
+ }
+ // Do add new libraries.
+ for (var library in newComponent.libraries) {
+ if (!partFileUris.contains(library.fileUri)) {
+ Uri uri = library.importUri;
+ if (!_component.root.hasChild('$uri')) {
+ _component.root.getChildFromUri(uri).bindTo(library.reference);
+ library.computeCanonicalNames();
+ _component.libraries.add(library);
+ }
+ }
+ }
+ }
+
+ _logger.run('Compute dependencies', _computeDependencies);
+
+ // TODO(scheglov) Can we keep the same instance?
+ var types = new TypeEnvironment(
+ new CoreTypes(_component), new ClassHierarchy(_component));
+ return new LibraryOutlineResult(_component, types);
+ } finally {
+ _isCompileExecuting = false;
+ }
+ });
+ }
+
+ /// Compute resolution for the library with the given absolute [uri] and
+ /// all its parts.
+ ///
+ /// Throw [StateError] if another compilation is pending.
+ Future<LibraryCompilationResult> getResolution(Uri uri) {
+ if (_isCompileExecuting) {
+ throw new StateError(MSG_PENDING_COMPILE);
+ }
+ _isCompileExecuting = true;
+
+ return _runWithFrontEndContext('Compile', () async {
+ try {
+ // Remove the requested library outline from the component.
+ Library libraryOutline;
+ for (var library in _component.libraries) {
+ if (library.importUri == uri) {
+ libraryOutline = library;
+ _component.libraries.remove(library);
+ _component.root.removeChild('$uri');
+ break;
+ }
+ }
+ if (libraryOutline == null) {
+ throw new StateError('Expected to find $uri in the component.');
+ }
+ libraryOutline.canonicalName.getChild('IntWrapper');
+
+ var dillTarget =
+ new DillTarget(_options.ticker, uriTranslator, _options.target);
+
+ // Append all libraries what we still have in the current component.
+ await _logger.runAsync('Load dill libraries', () async {
dillTarget.loader.appendLibraries(_component);
await dillTarget.buildOutlines();
});
@@ -220,54 +302,54 @@
uriTranslator, new AnalyzerMetadataCollector());
kernelTarget.read(uri);
- // Compile the entry point into the new component.
- _component = await _logger.runAsync('Compile', () async {
- // TODO(brianwilkerson) Determine whether this await is necessary.
- await null;
+ // Resolve the requested library.
+ Component newComponent = await _logger.runAsync('Compile', () async {
await kernelTarget.buildOutlines(nameRoot: _component.root);
- return await kernelTarget.buildComponent() ?? _component;
+ return await kernelTarget.buildComponent();
});
- // TODO(scheglov) Only for new libraries?
- _component.computeCanonicalNames();
+ // Put the library outline back into the current component.
+ _component.root.adoptChild(libraryOutline.canonicalName);
+ _component.libraries.add(libraryOutline);
- _logger.run('Compute dependencies', _computeDependencies);
+ // Compute canonical names for the resolved library.
+ for (var library in newComponent.libraries) {
+ if (library.importUri == uri) {
+ library.reference.canonicalName = _component.root.getChild('$uri');
+ library.computeCanonicalNames();
+ break;
+ }
+ }
// TODO(scheglov) Can we keep the same instance?
var types = new TypeEnvironment(
new CoreTypes(_component), new ClassHierarchy(_component));
- // Add results for new libraries.
- for (var library in _component.libraries) {
- if (!_results.containsKey(library.importUri)) {
- Map<Uri, List<CollectedResolution>> libraryResolutions =
- kernelTarget.resolutions[library.fileUri];
+ Uri libraryFileUri = libraryOutline.fileUri;
+ var libraryResolutions = kernelTarget.resolutions[libraryFileUri];
+ if (libraryResolutions == null) {
+ throw new StateError('Expected to find $uri in resolutions.');
+ }
+ // TODO(scheglov) Check that we have exactly one resolution?
+ var files = <Uri, FileCompilationResult>{};
- var files = <Uri, FileCompilationResult>{};
-
- void addFileResult(Uri fileUri) {
- if (libraryResolutions != null) {
- files[fileUri] = new FileCompilationResult(
- fileUri,
- libraryResolutions[fileUri] ?? [],
- _errorListener.fileUriToErrors[fileUri] ?? []);
- }
- }
-
- addFileResult(library.fileUri);
- for (var part in library.parts) {
- addFileResult(library.fileUri.resolve(part.partUri));
- }
-
- var libraryResult = new LibraryCompilationResult(
- _component, types, library.importUri, library, files);
- _results[library.importUri] = libraryResult;
+ void addFileResult(Uri fileUri) {
+ if (libraryResolutions != null) {
+ files[fileUri] = new FileCompilationResult(
+ fileUri,
+ libraryResolutions[fileUri] ?? [],
+ _errorListener.fileUriToErrors[fileUri] ?? []);
}
}
+
+ addFileResult(libraryFileUri);
+ for (var part in libraryOutline.parts) {
+ addFileResult(libraryFileUri.resolve(part.partUri));
+ }
_errorListener.fileUriToErrors.clear();
- // The result must have been computed.
- return _results[uri];
+ return new LibraryCompilationResult(
+ _component, types, libraryOutline.importUri, libraryOutline, files);
} finally {
_isCompileExecuting = false;
}
@@ -276,7 +358,7 @@
/// Invalidate the file with the given file [uri], its library and the
/// transitive the of libraries that use it. The next time when any of these
- /// libraries is be requested in [compile], it will be recompiled again.
+ /// libraries is be requested in [getResolution], it will be recompiled again.
void invalidate(Uri uri) {
void invalidateLibrary(Uri libraryUri) {
Library library = _uriToLibrary.remove(libraryUri);
@@ -286,7 +368,6 @@
_component.libraries.remove(library);
_component.root.removeChild('${library.importUri}');
_component.uriToSource.remove(libraryUri);
- _results.remove(library.importUri);
// Recursively invalidate dependencies.
Set<Uri> directDependencies =
@@ -363,6 +444,20 @@
this.component, this.types, this.uri, this.kernel, this.files);
}
+/// The outline result for a single library.
+class LibraryOutlineResult {
+ /// The full current [Component]. It has all libraries that are required by
+ /// this library, but might also have other libraries, that are not required.
+ ///
+ /// The object is mutable, and is changed when files are invalidated.
+ final Component component;
+
+ /// The [TypeEnvironment] for the [component].
+ final TypeEnvironment types;
+
+ LibraryOutlineResult(this.component, this.types);
+}
+
/// The [DietListener] that record resolution information.
class _AnalyzerDietListener extends DietListener {
final Map<Uri, List<CollectedResolution>> _resolutions;
diff --git a/pkg/analyzer/lib/src/dart/analysis/kernel_context.dart b/pkg/analyzer/lib/src/dart/analysis/kernel_context.dart
index 868599ed..4a9b2c5 100644
--- a/pkg/analyzer/lib/src/dart/analysis/kernel_context.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/kernel_context.dart
@@ -84,15 +84,14 @@
// TODO(brianwilkerson) Determine whether this await is necessary.
await null;
Uri targetUri = targetLibrary.uri;
- LibraryCompilationResult compilationResult =
- await compiler.compile(targetUri);
+ LibraryOutlineResult outlineResult = await compiler.getOutline(targetUri);
// Remember Kernel libraries produced by the compiler.
// There might be more libraries than we actually need.
// This is probably OK, because we consume them lazily.
var libraryMap = <String, kernel.Library>{};
var libraryExistMap = <String, bool>{};
- for (var library in compilationResult.component.libraries) {
+ for (var library in outlineResult.component.libraries) {
String uriStr = library.importUri.toString();
libraryMap[uriStr] = library;
FileState file = fsState.getFileForUri(library.importUri);
@@ -116,8 +115,8 @@
analysisContext.contentCache = new _ContentCacheWrapper(fsState);
// Create the resynthesizer bound to the analysis context.
- var resynthesizer = new KernelResynthesizer(analysisContext,
- compilationResult.types, libraryMap, libraryExistMap);
+ var resynthesizer = new KernelResynthesizer(
+ analysisContext, outlineResult.types, libraryMap, libraryExistMap);
return new KernelContext._(analysisContext, resynthesizer);
});
diff --git a/pkg/analyzer/lib/src/dart/analysis/library_analyzer.dart b/pkg/analyzer/lib/src/dart/analysis/library_analyzer.dart
index c58b12b..709f366 100644
--- a/pkg/analyzer/lib/src/dart/analysis/library_analyzer.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/library_analyzer.dart
@@ -182,11 +182,7 @@
}
Future<Map<FileState, UnitAnalysisResult>> _analyze2() async {
- // TODO(brianwilkerson) Determine whether this await is necessary.
- await null;
return await _logger.runAsync('Analyze', () async {
- // TODO(brianwilkerson) Determine whether this await is necessary.
- await null;
Map<FileState, CompilationUnit> units = {};
// Parse all files.
@@ -209,7 +205,7 @@
_resolveDirectives(units);
var libraryResult = await _logger.runAsync('Compile library', () {
- return _frontEndCompiler.compile(_library.uri);
+ return _frontEndCompiler.getResolution(_library.uri);
});
_logger.run('Apply resolution', () {
diff --git a/pkg/analyzer/lib/src/dart/analysis/search.dart b/pkg/analyzer/lib/src/dart/analysis/search.dart
index e017334..b5417e9 100644
--- a/pkg/analyzer/lib/src/dart/analysis/search.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/search.dart
@@ -387,7 +387,7 @@
if (index != null) {
for (AnalysisDriverSubtype subtype in index.subtypes) {
if (subtype.supertypes.contains(id)) {
- FileState library = file.isPart ? file.library : file;
+ FileState library = file.library ?? file;
results.add(new SubtypeResult(
library.uriStr,
library.uriStr + ';' + file.uriStr + ';' + subtype.name,
diff --git a/pkg/analyzer/lib/src/dart/ast/ast.dart b/pkg/analyzer/lib/src/dart/ast/ast.dart
index 457bb8e..f643697 100644
--- a/pkg/analyzer/lib/src/dart/ast/ast.dart
+++ b/pkg/analyzer/lib/src/dart/ast/ast.dart
@@ -6747,13 +6747,12 @@
if (int.parse(lexeme.substring(index, index + 1)) < 9) {
return true;
}
- int bound;
+ int bound = 223372036854775808;
if (isNegative) {
- bound = 223372036854775808;
+ return int.parse(lexeme.substring(index + 1)) <= bound;
} else {
- bound = 223372036854775807;
+ return int.parse(lexeme.substring(index + 1)) < bound;
}
- return int.parse(lexeme.substring(index + 1)) <= bound;
}
/**
diff --git a/pkg/analyzer/lib/src/error/codes.dart b/pkg/analyzer/lib/src/error/codes.dart
index 4be6d72..5d1bada 100644
--- a/pkg/analyzer/lib/src/error/codes.dart
+++ b/pkg/analyzer/lib/src/error/codes.dart
@@ -2400,6 +2400,28 @@
correction: "Try using a type that is or is a subclass of '{1}'.");
/**
+ * It is a compile-time error if a generic function type is used as a bound
+ * for a formal type parameter of a class or a function.
+ */
+ static const CompileTimeErrorCode GENERIC_FUNCTION_TYPE_CANNOT_BE_BOUND =
+ const CompileTimeErrorCode('GENERIC_FUNCTION_TYPE_CANNOT_BE_BOUND',
+ 'Generic function types may not be used as type parameter bounds',
+ correction: 'Try making the free variable in the function type part'
+ ' of the larger declaration signature');
+
+ /**
+ * It is a compile-time error if a generic function type is used as an actual
+ * type argument.
+ */
+ static const CompileTimeErrorCode GENERIC_FUNCTION_CANNOT_BE_TYPE_ARGUMENT =
+ const CompileTimeErrorCode(
+ 'GENERIC_FUNCTION_CANNOT_BE_TYPE_ARGUMENT',
+ "Generic function has type parameters '<{0}>', so it may not be used"
+ ' as a type argument',
+ correction: "Try removing the type parameters '<{0}>', or using"
+ " 'dynamic' as the type argument here instead of a function.");
+
+ /**
* 15.3.1 Typedef: Any self reference, either directly, or recursively via
* another typedef, is a compile time error.
*/
diff --git a/pkg/analyzer/lib/src/fasta/analyzer_expression_generator.dart b/pkg/analyzer/lib/src/fasta/analyzer_expression_generator.dart
deleted file mode 100644
index c007f79..0000000
--- a/pkg/analyzer/lib/src/fasta/analyzer_expression_generator.dart
+++ /dev/null
@@ -1,580 +0,0 @@
-// Copyright (c) 2018, 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.
-
-import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer/dart/ast/ast_factory.dart';
-import 'package:analyzer/src/fasta/ast_building_factory.dart';
-import 'package:front_end/src/fasta/kernel/expression_generator.dart' as fasta;
-import 'package:front_end/src/fasta/kernel/expression_generator_helper.dart';
-import 'package:front_end/src/fasta/kernel/forest.dart' as fasta;
-import 'package:front_end/src/scanner/token.dart';
-import 'package:kernel/ast.dart' as kernel
- show DartType, Initializer, Member, Name, Procedure;
-
-class AnalyzerDeferredAccessGenerator extends AnalyzerExpressionGenerator
- with fasta.DeferredAccessGenerator<Expression, Statement, Arguments> {
- final Token token;
- final fasta.PrefixBuilder builder;
- final fasta.Generator<Expression, Statement, Arguments> generator;
-
- AnalyzerDeferredAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.token,
- this.builder,
- this.generator)
- : super(helper, astFactory);
-
- @override
- Expression buildSimpleRead() => generator.buildSimpleRead();
-}
-
-class AnalyzerDelayedAssignmentGenerator extends AnalyzerExpressionGenerator
- with fasta.DelayedAssignment<Expression, Statement, Arguments> {
- final Token token;
- final fasta.Generator<Expression, Statement, Arguments> generator;
- final String assignmentOperator;
- final Expression value;
-
- AnalyzerDelayedAssignmentGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.token,
- this.generator,
- this.assignmentOperator,
- this.value)
- : super(helper, astFactory);
-
- @override
- Expression buildSimpleRead() => astFactory.assignmentExpression(
- generator.buildSimpleRead(), token, value);
-
- @override
- Expression doInvocation(int offset, Arguments arguments) => buildSimpleRead();
-}
-
-class AnalyzerDelayedPostfixIncrementGenerator
- extends AnalyzerExpressionGenerator
- with fasta.DelayedPostfixIncrement<Expression, Statement, Arguments> {
- final Token token;
- final fasta.Generator<Expression, Statement, Arguments> generator;
- final kernel.Name binaryOperator;
- final kernel.Procedure interfaceTarget;
-
- AnalyzerDelayedPostfixIncrementGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.token,
- this.generator,
- this.binaryOperator,
- this.interfaceTarget)
- : super(helper, astFactory);
-
- @override
- Expression buildSimpleRead() =>
- astFactory.postfixExpression(generator.buildSimpleRead(), token);
-
- @override
- Expression doInvocation(int offset, Arguments arguments) => buildSimpleRead();
-}
-
-abstract class AnalyzerExpressionGenerator
- implements fasta.Generator<Expression, Statement, Arguments> {
- final ExpressionGeneratorHelper<Expression, Statement, Arguments> helper;
-
- final AstFactory astFactory;
-
- AnalyzerExpressionGenerator(this.helper, this.astFactory);
-
- fasta.Forest<Expression, Statement, Token, Arguments> get forest =>
- helper.forest;
-
- @override
-// TODO: implement isInitializer
- bool get isInitializer => throw new UnimplementedError();
-
- @override
-// TODO: implement isThisPropertyAccess
- bool get isThisPropertyAccess => throw new UnimplementedError();
-
- @override
-// TODO: implement plainNameForRead
- String get plainNameForRead => throw new UnimplementedError();
-
- @override
-// TODO: implement plainNameForWrite
- String get plainNameForWrite => throw new UnimplementedError();
-
- @override
-// TODO: implement uri
- Uri get uri => throw new UnimplementedError();
-
- @override
- Expression buildAssignment(Expression value, {bool voidContext}) {
- // TODO(brianwilkerson) Figure out how to get the token for the operator.
- return astFactory.assignmentExpression(buildSimpleRead(), null, value);
- }
-
- @override
- Expression buildCompoundAssignment(
- kernel.Name binaryOperator, Expression value,
- {int offset,
- bool voidContext,
- kernel.Procedure interfaceTarget,
- bool isPreIncDec}) {
- // TODO(brianwilkerson) Figure out how to get the token for the operator.
- return astFactory.assignmentExpression(buildSimpleRead(), null, value);
- }
-
- @override
- kernel.Initializer buildFieldInitializer(Map<String, int> initializedFields) {
- // TODO: implement buildFieldInitializer
- throw new UnimplementedError();
- }
-
- /// For most accessors, the AST structure will be the same whether the result
- /// is being used for access or modification.
- Expression buildForEffect() => buildSimpleRead();
-
- @override
- Expression buildNullAwareAssignment(
- Expression value, kernel.DartType type, int offset,
- {bool voidContext}) {
- // TODO(brianwilkerson) Figure out how to get the token for the operator.
- // TODO(brianwilkerson) Capture the type information?
- return astFactory.assignmentExpression(buildSimpleRead(), null, value);
- }
-
- @override
- Expression buildPostfixIncrement(kernel.Name binaryOperator,
- {int offset, bool voidContext, kernel.Procedure interfaceTarget}) {
- // TODO(brianwilkerson) Figure out how to get the token for the operator.
- return astFactory.postfixExpression(buildSimpleRead(), null);
- }
-
- @override
- Expression buildPrefixIncrement(kernel.Name binaryOperator,
- {int offset, bool voidContext, kernel.Procedure interfaceTarget}) {
- // TODO(brianwilkerson) Figure out how to get the token for the operator.
- return astFactory.prefixExpression(null, buildSimpleRead());
- }
-
- @override
- buildPropertyAccess(fasta.IncompleteSendGenerator send, int operatorOffset,
- bool isNullAware) {
- // TODO: implement buildPropertyAccess
-// return astFactory.propertyAccess(buildSimpleRead(), null, null);
- throw new UnimplementedError();
- }
-
- @override
- buildThrowNoSuchMethodError(Expression receiver, Arguments arguments,
- {bool isSuper,
- bool isGetter,
- bool isSetter,
- bool isStatic,
- String name,
- int offset,
- /*LocatedMessage*/ argMessage}) {
- // TODO: implement buildThrowNoSuchMethodError
- throw new UnimplementedError();
- }
-
- @override
- kernel.DartType buildTypeWithBuiltArguments(List<kernel.DartType> arguments,
- {bool nonInstanceAccessIsError: false}) {
- // TODO: implement buildTypeWithBuiltArguments
- throw new UnimplementedError();
- }
-
- @override
- doInvocation(int offset, Arguments arguments) {
- // TODO: implement doInvocation
- throw new UnimplementedError();
- }
-
- @override
- Expression makeInvalidRead() {
- // TODO: implement makeInvalidRead
- throw new UnimplementedError();
- }
-
- @override
- Expression makeInvalidWrite(Expression value) {
- // TODO: implement makeInvalidWrite
- throw new UnimplementedError();
- }
-
- @override
- void printOn(StringSink sink) {
- // TODO: implement printOn
- throw new UnimplementedError();
- }
-
- @override
- T storeOffset<T>(T node, int offset) {
- // TODO: implement storeOffset
- throw new UnimplementedError();
- }
-}
-
-class AnalyzerIndexedAccessGenerator extends AnalyzerExpressionGenerator
- with fasta.IndexedAccessGenerator<Expression, Statement, Arguments> {
- /// The expression computing the object on which the index operation will be
- /// invoked.
- final Expression target;
-
- /// The left bracket.
- final Token leftBracket;
-
- /// The expression computing the argument for the index operation.
- final Expression index;
-
- /// The right bracket.
- final Token rightBracket;
-
- /// Initialize a newly created generator to have the given helper.
- AnalyzerIndexedAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.target,
- this.leftBracket,
- this.index,
- this.rightBracket)
- : super(helper, astFactory);
-
- @override
- Token get token => leftBracket;
-
- @override
- Expression buildSimpleRead() => astFactory.indexExpressionForTarget(
- target, leftBracket, index, rightBracket);
-}
-
-class AnalyzerLargeIntAccessGenerator extends AnalyzerExpressionGenerator
- with fasta.LargeIntAccessGenerator<Expression, Statement, Arguments> {
- final Token token;
-
- AnalyzerLargeIntAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.token)
- : super(helper, astFactory);
-
- @override
- Expression buildSimpleRead() => astFactory.integerLiteral(token, null);
-}
-
-class AnalyzerLoadLibraryGenerator extends AnalyzerExpressionGenerator
- with fasta.LoadLibraryGenerator<Expression, Statement, Arguments> {
- final Token token;
- final fasta.LoadLibraryBuilder builder;
-
- AnalyzerLoadLibraryGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.token,
- this.builder)
- : super(helper, astFactory);
-
- @override
- Expression buildSimpleRead() {
- // TODO: implement buildSimpleRead
- throw new UnimplementedError();
- }
-}
-
-class AnalyzerNullAwarePropertyAccessGenerator
- extends AnalyzerExpressionGenerator
- with
- fasta.NullAwarePropertyAccessGenerator<Expression, Statement,
- Arguments> {
- final Expression target;
- final Token operator;
- final SimpleIdentifier propertyName;
-
- AnalyzerNullAwarePropertyAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.target,
- this.operator,
- this.propertyName)
- : super(helper, astFactory);
-
- @override
- Token get token => operator;
-
- @override
- Expression buildSimpleRead() =>
- astFactory.propertyAccess(target, operator, propertyName);
-}
-
-class AnalyzerPropertyAccessGenerator extends AnalyzerExpressionGenerator
- with fasta.PropertyAccessGenerator<Expression, Statement, Arguments> {
- final Token token;
- final Expression receiver;
- final kernel.Name name;
- final kernel.Member getter;
- final kernel.Member setter;
-
- AnalyzerPropertyAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.token,
- this.receiver,
- this.name,
- this.getter,
- this.setter)
- : super(helper, astFactory);
-
- @override
- // TODO(brianwilkerson) Figure out how to get the property name token (or node).
- Expression buildSimpleRead() =>
- astFactory.propertyAccess(receiver, token, null);
-}
-
-class AnalyzerReadOnlyAccessGenerator extends AnalyzerExpressionGenerator
- with fasta.ReadOnlyAccessGenerator<Expression, Statement, Arguments> {
- final Token token;
- final Expression expression;
- final String plainNameForRead;
-
- AnalyzerReadOnlyAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.token,
- this.expression,
- this.plainNameForRead)
- : super(helper, astFactory);
-
- @override
- Expression buildSimpleRead() {
- // TODO: implement buildSimpleRead
- throw new UnimplementedError();
- }
-}
-
-class AnalyzerStaticAccessGenerator extends AnalyzerExpressionGenerator
- with fasta.StaticAccessGenerator<Expression, Statement, Arguments> {
- final Token token;
- final kernel.Member getter;
- final kernel.Member setter;
-
- AnalyzerStaticAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.token,
- this.getter,
- this.setter)
- : super(helper, astFactory);
-
- @override
- kernel.Member get readTarget {
- // TODO: implement readTarget
- throw new UnimplementedError();
- }
-
- @override
- Expression buildSimpleRead() {
- // TODO: implement buildSimpleRead
- throw new UnimplementedError();
- }
-}
-
-class AnalyzerSuperIndexedAccessGenerator extends AnalyzerExpressionGenerator
- with fasta.SuperIndexedAccessGenerator<Expression, Statement, Arguments> {
- /// The expression computing the object on which the index operation will be
- /// invoked.
- final Expression target;
-
- /// The left bracket.
- final Token leftBracket;
-
- /// The expression computing the argument for the index operation.
- final Expression index;
-
- /// The right bracket.
- final Token rightBracket;
-
- /// Initialize a newly created generator to have the given helper.
- AnalyzerSuperIndexedAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.target,
- this.leftBracket,
- this.index,
- this.rightBracket)
- : super(helper, astFactory);
-
- @override
- Token get token => leftBracket;
-
- @override
- Expression buildSimpleRead() => astFactory.indexExpressionForTarget(
- target, leftBracket, index, rightBracket);
-}
-
-class AnalyzerSuperPropertyAccessGenerator extends AnalyzerExpressionGenerator
- with fasta.SuperPropertyAccessGenerator<Expression, Statement, Arguments> {
- /// The `super` keyword.
- Token superKeyword;
-
- /// The `.` or `?.` operator.
- Token operator;
-
- /// The name of the property being accessed,
- SimpleIdentifier propertyName;
-
- AnalyzerSuperPropertyAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.superKeyword,
- this.operator,
- this.propertyName)
- : super(helper, astFactory);
-
- @override
- Token get token => operator;
-
- @override
- Expression buildSimpleRead() => astFactory.propertyAccess(
- astFactory.superExpression(superKeyword), operator, propertyName);
-}
-
-class AnalyzerThisIndexedAccessGenerator extends AnalyzerExpressionGenerator
- with fasta.ThisIndexedAccessGenerator<Expression, Statement, Arguments> {
- /// The expression computing the object on which the index operation will be
- /// invoked.
- final Expression target;
-
- /// The left bracket.
- final Token leftBracket;
-
- /// The expression computing the argument for the index operation.
- final Expression index;
-
- /// The right bracket.
- final Token rightBracket;
-
- /// Initialize a newly created generator to have the given helper.
- AnalyzerThisIndexedAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.target,
- this.leftBracket,
- this.index,
- this.rightBracket)
- : super(helper, astFactory);
-
- @override
- Token get token => leftBracket;
-
- @override
- Expression buildSimpleRead() => astFactory.indexExpressionForTarget(
- target, leftBracket, index, rightBracket);
-}
-
-class AnalyzerThisPropertyAccessGenerator extends AnalyzerExpressionGenerator
- with fasta.ThisPropertyAccessGenerator<Expression, Statement, Arguments> {
- final Token token;
- final kernel.Name name;
- final kernel.Member getter;
- final kernel.Member setter;
-
- AnalyzerThisPropertyAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.token,
- this.name,
- this.getter,
- this.setter)
- : super(helper, astFactory);
-
- @override
- // TODO(brianwilkerson) Figure out how to get the token (or node) for `this`.
- // TODO(brianwilkerson) Figure out how to get the property name token (or node).
- Expression buildSimpleRead() => astFactory.propertyAccess(null, token, null);
-}
-
-class AnalyzerTypeUseGenerator extends AnalyzerExpressionGenerator
- with fasta.TypeUseGenerator<Expression, Statement, Arguments> {
- final Token token;
- final fasta.PrefixBuilder prefix;
- final int declarationReferenceOffset;
- final fasta.TypeDeclarationBuilder declaration;
- final String plainNameForRead;
-
- AnalyzerTypeUseGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.token,
- this.prefix,
- this.declarationReferenceOffset,
- this.declaration,
- this.plainNameForRead)
- : super(helper, astFactory);
-
- @override
- Expression buildSimpleRead() {
- // TODO: implement buildSimpleRead
- throw new UnimplementedError();
- }
-}
-
-class AnalyzerUnlinkedNameGenerator extends AnalyzerExpressionGenerator
- with fasta.UnlinkedGenerator<Expression, Statement, Arguments> {
- @override
- final Token token;
-
- @override
- final fasta.UnlinkedDeclaration declaration;
-
- AnalyzerUnlinkedNameGenerator(
- ExpressionGeneratorHelper<dynamic, dynamic, dynamic> helper,
- AstFactory astFactory,
- this.token,
- this.declaration)
- : super(helper, astFactory);
-
- @override
- Expression buildSimpleRead() => astFactory.simpleIdentifier(token);
-}
-
-class AnalyzerUnresolvedNameGenerator extends AnalyzerExpressionGenerator
- with
- fasta.ErroneousExpressionGenerator<Expression, Statement, Arguments>,
- fasta.UnresolvedNameGenerator<Expression, Statement, Arguments> {
- @override
- final Token token;
-
- @override
- final kernel.Name name;
-
- AnalyzerUnresolvedNameGenerator(
- ExpressionGeneratorHelper<dynamic, dynamic, dynamic> helper,
- AstFactory astFactory,
- this.token,
- this.name)
- : super(helper, astFactory);
-
- @override
- Expression buildSimpleRead() => astFactory.simpleIdentifier(token);
-}
-
-class AnalyzerVariableUseGenerator extends AnalyzerExpressionGenerator
- with fasta.VariableUseGenerator<Expression, Statement, Arguments> {
- final Token nameToken;
-
- AnalyzerVariableUseGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- AstFactory astFactory,
- this.nameToken)
- : super(helper, astFactory);
-
- @override
- Token get token => nameToken;
-
- @override
- Expression buildSimpleRead() => astFactory.simpleIdentifier(nameToken);
-}
diff --git a/pkg/analyzer/lib/src/fasta/ast_body_builder.dart b/pkg/analyzer/lib/src/fasta/ast_body_builder.dart
deleted file mode 100644
index f79a164..0000000
--- a/pkg/analyzer/lib/src/fasta/ast_body_builder.dart
+++ /dev/null
@@ -1,49 +0,0 @@
-// Copyright (c) 2018, 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.
-
-import 'package:analyzer/dart/ast/ast.dart' show Expression, Statement;
-import 'package:analyzer/src/fasta/ast_building_factory.dart'
- show Arguments, AstBuildingForest;
-import 'package:analyzer/src/generated/resolver.dart' show TypeProvider;
-import 'package:front_end/src/fasta/kernel/body_builder.dart' show BodyBuilder;
-import 'package:front_end/src/fasta/kernel/kernel_builder.dart'
- show KernelClassBuilder, KernelLibraryBuilder, ModifierBuilder, Scope;
-import 'package:front_end/src/fasta/type_inference/type_inferrer.dart'
- show TypeInferrer;
-import 'package:kernel/class_hierarchy.dart' show ClassHierarchy;
-import 'package:kernel/core_types.dart' show CoreTypes;
-
-export 'package:front_end/src/fasta/kernel/unlinked_scope.dart'
- show UnlinkedScope;
-
-class AstBodyBuilder extends BodyBuilder<Expression, Statement, Arguments> {
- @override
- final AstBuildingForest forest;
-
- AstBodyBuilder(
- KernelLibraryBuilder library,
- ModifierBuilder member,
- Scope scope,
- Scope formalParameterScope,
- ClassHierarchy hierarchy,
- CoreTypes coreTypes,
- KernelClassBuilder classBuilder,
- bool isInstanceMember,
- Uri uri,
- TypeInferrer typeInferrer,
- TypeProvider typeProvider)
- : forest = new AstBuildingForest(typeProvider),
- super(library, member, scope, formalParameterScope, hierarchy,
- coreTypes, classBuilder, isInstanceMember, uri, typeInferrer);
-
- @override
- void enterThenForTypePromotion(Expression condition) {
- // Do nothing.
- }
-
- @override
- void logEvent(String name) {
- throw "Parser event '$name' not implemented";
- }
-}
diff --git a/pkg/analyzer/lib/src/fasta/ast_builder.dart b/pkg/analyzer/lib/src/fasta/ast_builder.dart
index 54f5982..097764a 100644
--- a/pkg/analyzer/lib/src/fasta/ast_builder.dart
+++ b/pkg/analyzer/lib/src/fasta/ast_builder.dart
@@ -2166,35 +2166,44 @@
}
@override
- void beginTypeVariable(Token name) {
+ void beginTypeVariable(Token token) {
debugEvent("beginTypeVariable");
+ SimpleIdentifier name = pop();
+ List<Annotation> metadata = pop();
+
+ Comment comment = _findComment(metadata, name.beginToken);
+ push(ast.typeParameter(comment, metadata, name, null, null));
}
@override
- void endTypeVariable(Token token, Token extendsOrSuper) {
- // TODO(paulberry): set up scopes properly to resolve parameters and type
- // variables. Note that this is tricky due to the handling of initializers
- // in constructors, so the logic should be shared with BodyBuilder as much
- // as possible.
+ void handleTypeVariablesDefined(Token token, int count) {
+ debugEvent("handleTypeVariablesDefined");
+ assert(count > 0);
+ push(popTypedList(count, new List<TypeParameter>(count)));
+ }
+
+ @override
+ void endTypeVariable(Token token, int index, Token extendsOrSuper) {
+ debugEvent("TypeVariable");
assert(extendsOrSuper == null ||
optional('extends', extendsOrSuper) ||
optional('super', extendsOrSuper));
- debugEvent("TypeVariable");
-
TypeAnnotation bound = pop();
- SimpleIdentifier name = pop();
- List<Annotation> metadata = pop();
- Comment comment = _findComment(metadata, name.beginToken);
- push(ast.typeParameter(comment, metadata, name, extendsOrSuper, bound));
+
+ // Peek to leave type parameters on top of stack.
+ List<TypeParameter> typeParameters = peek();
+ typeParameters[index]
+ ..extendsKeyword = extendsOrSuper
+ ..bound = bound;
}
@override
- void endTypeVariables(int count, Token beginToken, Token endToken) {
+ void endTypeVariables(Token beginToken, Token endToken) {
assert(optional('<', beginToken));
assert(optional('>', endToken));
debugEvent("TypeVariables");
- List<TypeParameter> typeParameters = popTypedList(count);
+ List<TypeParameter> typeParameters = pop();
push(ast.typeParameterList(beginToken, typeParameters, endToken));
}
diff --git a/pkg/analyzer/lib/src/fasta/ast_building_factory.dart b/pkg/analyzer/lib/src/fasta/ast_building_factory.dart
deleted file mode 100644
index 436b733..0000000
--- a/pkg/analyzer/lib/src/fasta/ast_building_factory.dart
+++ /dev/null
@@ -1,690 +0,0 @@
-// Copyright (c) 2018, 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.
-
-import 'package:analyzer/dart/ast/ast.dart' hide Identifier;
-import 'package:analyzer/dart/ast/token.dart';
-import 'package:analyzer/src/dart/ast/ast_factory.dart';
-import 'package:analyzer/src/fasta/analyzer_expression_generator.dart';
-import 'package:analyzer/src/generated/resolver.dart' show TypeProvider;
-import 'package:front_end/src/fasta/kernel/body_builder.dart' show LabelTarget;
-import 'package:front_end/src/fasta/kernel/forest.dart';
-import 'package:kernel/ast.dart' as kernel;
-
-/// A data holder used to conform to the [Forest] API.
-class Arguments {
- List<TypeAnnotation> typeArguments = <TypeAnnotation>[];
- List<Expression> positionalArguments = <Expression>[];
- List<Expression> namedArguments = <Expression>[];
-}
-
-/// An implementation of a [Forest] that can be used to build an AST structure.
-class AstBuildingForest
- implements Forest<Expression, Statement, Token, Arguments> {
- /// The type provider used to resolve the types of literal nodes, or `null` if
- /// type resolution is not being performed.
- final TypeProvider _typeProvider;
-
- /// The factory used to create AST nodes.
- AstFactoryImpl astFactory = new AstFactoryImpl();
-
- /// Initialize a newly created AST-building forest.
- AstBuildingForest(this._typeProvider);
-
- @override
- Arguments arguments(List<Expression> positional, Token location,
- {covariant List types, covariant List named}) {
- Arguments arguments = new Arguments();
- if (types != null) {
- arguments.typeArguments = types.cast<TypeAnnotation>();
- }
- arguments.positionalArguments = positional.cast<Expression>();
- if (named != null) {
- arguments.namedArguments = named.cast<Expression>();
- }
- return arguments;
- }
-
- @override
- Arguments argumentsEmpty(Token location) => new Arguments();
-
- @override
- List argumentsNamed(Arguments arguments) => arguments.namedArguments;
-
- @override
- List<Expression> argumentsPositional(Arguments arguments) =>
- arguments.positionalArguments;
-
- @override
- void argumentsSetTypeArguments(Arguments arguments, covariant List types) {
- arguments.typeArguments = types.cast<TypeAnnotation>();
- }
-
- @override
- List argumentsTypeArguments(Arguments arguments) => arguments.typeArguments;
-
- @override
- Expression asExpression(Expression expression, type, Token location) =>
- astFactory.asExpression(expression, location, type);
-
- @override
- Expression asLiteralString(Expression value) => value;
-
- @override
- ConstructorInitializer assertInitializer(
- Token assertKeyword,
- Token leftParenthesis,
- Expression condition,
- Token comma,
- Expression message) =>
- astFactory.assertInitializer(assertKeyword, leftParenthesis, condition,
- comma, message, leftParenthesis.endGroup);
-
- @override
- Statement assertStatement(
- Token assertKeyword,
- Token leftParenthesis,
- Expression condition,
- Token comma,
- Expression message,
- Token semicolon) =>
- astFactory.assertStatement(assertKeyword, leftParenthesis, condition,
- comma, message, leftParenthesis.endGroup, semicolon);
-
- @override
- Expression awaitExpression(Expression operand, Token awaitKeyword) =>
- astFactory.awaitExpression(awaitKeyword, operand);
-
- @override
- Block block(Token openBrace, List<Statement> statements, Token closeBrace) =>
- astFactory.block(openBrace, statements, closeBrace);
-
- @override
- Statement breakStatement(
- Token breakKeyword, Identifier label, Token semicolon) =>
- astFactory.breakStatement(
- breakKeyword,
- label == null ? null : astFactory.simpleIdentifier(label.token),
- semicolon);
-
- @override
- kernel.Arguments castArguments(Arguments arguments) {
- // TODO(brianwilkerson) Implement this or remove it from the API.
- throw new UnimplementedError();
- }
-
- @override
- CatchClause catchClause(
- Token onKeyword,
- TypeAnnotation exceptionType,
- Token catchKeyword,
- SimpleIdentifier exceptionParameter,
- SimpleIdentifier stackTraceParameter,
- TypeAnnotation stackTraceType,
- Statement body) {
- // TODO(brianwilkerson) The following is not reliable in the presence of
- // recovery. Consider passing the required tokens from the Parser to the
- // BodyBuilder to here.
- Token leftParenthesis;
- if (catchKeyword != null) {
- leftParenthesis = catchKeyword.next;
- }
- Token comma;
- if (stackTraceParameter != null) {
- comma = exceptionParameter.endToken.next;
- }
- Token rightParenthesis;
- if (catchKeyword != null) {
- if (stackTraceParameter != null) {
- rightParenthesis = stackTraceParameter.endToken.next;
- } else if (comma != null) {
- rightParenthesis = comma.next;
- } else {
- rightParenthesis = exceptionParameter.endToken.next;
- }
- }
- return astFactory.catchClause(
- onKeyword,
- exceptionType,
- catchKeyword,
- leftParenthesis,
- exceptionParameter,
- comma,
- stackTraceParameter,
- rightParenthesis,
- body);
- }
-
- @override
- Expression checkLibraryIsLoaded(dependency) {
- // TODO(brianwilkerson) Implement this.
- throw new UnimplementedError();
- }
-
- @override
- Expression conditionalExpression(Expression condition, Token question,
- Expression thenExpression, Token colon, Expression elseExpression) =>
- astFactory.conditionalExpression(
- condition, question, thenExpression, colon, elseExpression);
-
- @override
- Statement continueStatement(
- Token continueKeyword, Identifier label, Token semicolon) =>
- astFactory.continueStatement(
- continueKeyword,
- label == null ? null : astFactory.simpleIdentifier(label.token),
- semicolon);
-
- @override
- Generator<Expression, Statement, Arguments> deferredAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- PrefixBuilder builder,
- Generator<Expression, Statement, Arguments> generator) {
- return new AnalyzerDeferredAccessGenerator(
- helper, astFactory, token, builder, generator);
- }
-
- @override
- Generator<Expression, Statement, Arguments> delayedAssignment(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- Generator<Expression, Statement, Arguments> generator,
- Expression value,
- String assignmentOperator) {
- return new AnalyzerDelayedAssignmentGenerator(
- helper, astFactory, token, generator, assignmentOperator, value);
- }
-
- @override
- Generator<Expression, Statement, Arguments> delayedPostfixIncrement(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- Generator<Expression, Statement, Arguments> generator,
- kernel.Name binaryOperator,
- kernel.Procedure interfaceTarget) {
- return new AnalyzerDelayedPostfixIncrementGenerator(
- helper, astFactory, token, generator, binaryOperator, interfaceTarget);
- }
-
- @override
- Statement doStatement(Token doKeyword, Statement body, Token whileKeyword,
- ParenthesizedExpression condition, Token semicolon) =>
- astFactory.doStatement(
- doKeyword,
- body,
- whileKeyword,
- condition.leftParenthesis,
- condition.expression,
- condition.rightParenthesis,
- semicolon);
-
- @override
- Statement emptyStatement(Token semicolon) =>
- astFactory.emptyStatement(semicolon);
-
- @override
- Statement expressionStatement(Expression expression, Token semicolon) =>
- astFactory.expressionStatement(expression, semicolon);
-
- @override
- Statement forStatement(
- Token forKeyword,
- Token leftParenthesis,
- covariant variableList,
- covariant initialization,
- Token leftSeparator,
- Expression condition,
- Statement conditionStatement,
- List<Expression> updaters,
- Token rightParenthesis,
- Statement body) =>
- astFactory.forStatement(
- forKeyword,
- leftParenthesis,
- variableList,
- initialization,
- leftSeparator,
- condition,
- getSemicolon(conditionStatement),
- updaters,
- rightParenthesis,
- body);
-
- @override
- Expression getExpressionFromExpressionStatement(Statement statement) =>
- (statement as ExpressionStatement).expression;
-
- String getLabelName(Label label) => label.label.name;
-
- @override
- int getLabelOffset(Label label) => label.offset;
-
- /// Return the semicolon at the end of the given [statement], or `null` if the
- /// statement is not terminated by a semicolon.
- Token getSemicolon(Statement statement) {
- if (statement is ExpressionStatement) {
- return statement.semicolon;
- }
- if (statement is EmptyStatement) {
- return statement.semicolon;
- }
- return null;
- }
-
- @override
- kernel.DartType getTypeAt(TypeArgumentList typeArguments, int index) {
- return null; // typeArguments.arguments[index].type.kernelType;
- }
-
- @override
- int getTypeCount(TypeArgumentList typeArguments) =>
- typeArguments.arguments.length;
-
- @override
- String getVariableDeclarationName(VariableDeclaration declaration) {
- return declaration.name.name;
- }
-
- @override
- Statement ifStatement(
- Token ifKeyword,
- ParenthesizedExpression condition,
- Statement thenStatement,
- Token elseKeyword,
- Statement elseStatement) =>
- astFactory.ifStatement(
- ifKeyword,
- condition.leftParenthesis,
- condition.expression,
- condition.rightParenthesis,
- thenStatement,
- elseKeyword,
- elseStatement);
-
- @override
- Generator<Expression, Statement, Arguments> indexedAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- Expression receiver,
- Expression index,
- kernel.Procedure getter,
- kernel.Procedure setter) {
- return new AnalyzerIndexedAccessGenerator(
- helper, astFactory, receiver, token, index, token.endGroup);
- }
-
- @override
- bool isBlock(Object node) => node is Block;
-
- @override
- bool isEmptyStatement(Statement statement) => statement is EmptyStatement;
-
- @override
- bool isErroneousNode(Object node) => false /* ??? */;
-
- @override
- Expression isExpression(Expression expression, Token isOperator,
- Token notOperator, Object type) =>
- astFactory.isExpression(expression, isOperator, notOperator, type);
-
- @override
- bool isExpressionStatement(Statement statement) =>
- statement is ExpressionStatement;
-
- @override
- bool isLabel(covariant node) => node is Label;
-
- @override
- bool isThisExpression(Object node) => node is ThisExpression;
-
- @override
- bool isVariablesDeclaration(Object node) =>
- node is VariableDeclarationStatement && node.variables != 1;
-
- @override
- Label label(Token identifier, Token colon) => astFactory.label(
- astFactory.simpleIdentifier(identifier, isDeclaration: true), colon);
-
- @override
- Statement labeledStatement(
- LabelTarget<Statement> target, Statement statement) =>
- astFactory.labeledStatement(target.labels.cast<Label>(), statement);
-
- @override
- Generator<Expression, Statement, Arguments> largeIntAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token) {
- return new AnalyzerLargeIntAccessGenerator(helper, astFactory, token);
- }
-
- @override
- Expression literalBool(bool value, Token location) =>
- astFactory.booleanLiteral(location, value)
- ..staticType = _typeProvider?.boolType;
-
- @override
- Expression literalDouble(double value, Token location) =>
- astFactory.doubleLiteral(location, value)
- ..staticType = _typeProvider?.doubleType;
-
- @override
- Expression literalInt(int value, Token location) =>
- astFactory.integerLiteral(location, value)
- ..staticType = _typeProvider?.intType;
-
- @override
- Expression literalList(
- Token constKeyword,
- bool isConst,
- Object typeArgument,
- Object typeArguments,
- Token leftBracket,
- List<Expression> expressions,
- Token rightBracket) =>
- astFactory.listLiteral(
- constKeyword, typeArguments, leftBracket, expressions, rightBracket);
-
- @override
- Expression literalMap(
- Token constKeyword,
- bool isConst,
- covariant keyType,
- covariant valueType,
- Object typeArguments,
- Token leftBracket,
- covariant List entries,
- Token rightBracket) =>
- astFactory.mapLiteral(
- constKeyword, typeArguments, leftBracket, entries, rightBracket);
-
- @override
- Expression literalNull(Token location) =>
- astFactory.nullLiteral(location)..staticType = _typeProvider?.nullType;
-
- @override
- Expression literalString(String value, Token location) =>
- astFactory.simpleStringLiteral(location, value)
- ..staticType = _typeProvider?.stringType;
-
- @override
- Expression literalSymbolMultiple(
- String value, Token hash, List<Identifier> components) =>
- astFactory.symbolLiteral(
- hash, components.map((identifier) => identifier.token).toList())
- ..staticType = _typeProvider?.symbolType;
-
- @override
- Expression literalSymbolSingluar(String value, Token hash, Object component) {
- Token token;
- if (component is Identifier) {
- token = component.token;
- } else if (component is Operator) {
- token = component.token;
- } else {
- throw new ArgumentError(
- 'Unexpected class of component: ${component.runtimeType}');
- }
- return astFactory.symbolLiteral(hash, <Token>[token])
- ..staticType = _typeProvider?.symbolType;
- }
-
- @override
- Expression literalType(covariant type, Token location) {
- // TODO(brianwilkerson) Capture the type information.
- return astFactory.simpleIdentifier(location)
- ..staticType = _typeProvider?.typeType;
- }
-
- @override
- Expression loadLibrary(dependency) {
- // TODO(brianwilkerson) Implement this.
- throw new UnimplementedError();
- }
-
- @override
- Generator<Expression, Statement, Arguments> loadLibraryGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- LoadLibraryBuilder builder) {
- return new AnalyzerLoadLibraryGenerator(helper, astFactory, token, builder);
- }
-
- @override
- Expression logicalExpression(
- Expression leftOperand, Token operator, Expression rightOperand) =>
- astFactory.binaryExpression(leftOperand, operator, rightOperand);
-
- @override
- Object mapEntry(Expression key, Token colon, Expression value) =>
- astFactory.mapLiteralEntry(key, colon, value);
-
- @override
- List mapEntryList(int length) => new List<MapLiteralEntry>(length);
-
- @override
- Expression notExpression(Expression operand, Token operator) =>
- astFactory.prefixExpression(operator, operand)
- ..staticType = _typeProvider?.boolType;
-
- @override
- Generator<Expression, Statement, Arguments> nullAwarePropertyAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- Expression receiverExpression,
- kernel.Name name,
- kernel.Member getter,
- kernel.Member setter,
- kernel.DartType type) {
- return new AnalyzerNullAwarePropertyAccessGenerator(
- helper, astFactory, receiverExpression, token, null /*name*/);
- }
-
- @override
- Object parenthesizedCondition(Token leftParenthesis, Expression expression,
- Token rightParenthesis) =>
- astFactory.parenthesizedExpression(
- leftParenthesis, expression, rightParenthesis);
-
- @override
- Generator<Expression, Statement, Arguments> propertyAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- Expression receiver,
- kernel.Name name,
- kernel.Member getter,
- kernel.Member setter) {
- return new AnalyzerPropertyAccessGenerator(
- helper, astFactory, token, receiver, name, getter, setter);
- }
-
- @override
- int readOffset(AstNode node) => node.offset;
-
- @override
- Generator<Expression, Statement, Arguments> readOnlyAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- Expression expression,
- String plainNameForRead) {
- return new AnalyzerReadOnlyAccessGenerator(
- helper, astFactory, token, expression, plainNameForRead);
- }
-
- @override
- void resolveBreak(Statement target, BreakStatement user) {
- user.target = target;
- }
-
- @override
- void resolveContinue(Statement target, ContinueStatement user) {
- user.target = target;
- }
-
- @override
- void resolveContinueInSwitch(SwitchStatement target, ContinueStatement user) {
- user.target = target;
- }
-
- @override
- Statement rethrowStatement(Token rethrowKeyword, Token semicolon) =>
- astFactory.expressionStatement(
- astFactory.rethrowExpression(rethrowKeyword), semicolon);
-
- @override
- Statement returnStatement(
- Token returnKeyword, Expression expression, Token semicolon) =>
- astFactory.returnStatement(returnKeyword, expression, semicolon);
-
- @override
- void setParameterType(FormalParameter parameter, TypeAnnotation type) {
- parameter.identifier.staticType = type.type;
- }
-
- @override
- Generator<Expression, Statement, Arguments> staticAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- kernel.Member getter,
- kernel.Member setter) {
- return new AnalyzerStaticAccessGenerator(
- helper, astFactory, token, getter, setter);
- }
-
- @override
- Expression stringConcatenationExpression(
- List<Expression> strings, Token location) =>
- astFactory.adjacentStrings(strings.cast<StringLiteral>());
-
- @override
- Generator<Expression, Statement, Arguments> superIndexedAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- Expression index,
- kernel.Member getter,
- kernel.Member setter) {
- // TODO(brianwilkerson) Figure out how to get the token for `super`.
- return new AnalyzerIndexedAccessGenerator(
- helper, astFactory, null, token, index, token.endGroup);
- }
-
- @override
- Generator<Expression, Statement, Arguments> superPropertyAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- kernel.Name name,
- kernel.Member getter,
- kernel.Member setter) {
- // TODO(brianwilkerson) Figure out how to get the token for the name.
- return new AnalyzerSuperPropertyAccessGenerator(
- helper, astFactory, null, null, null /*name*/);
- }
-
- @override
- Statement syntheticLabeledStatement(Statement statement) => statement;
-
- @override
- Expression thisExpression(Token thisKeyword) =>
- astFactory.thisExpression(thisKeyword);
-
- @override
- Generator<Expression, Statement, Arguments> thisIndexedAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- Expression index,
- kernel.Procedure getter,
- kernel.Procedure setter) {
- // TODO(brianwilkerson) Figure out how to get the token for `this`.
- return new AnalyzerIndexedAccessGenerator(
- helper, astFactory, null, token, index, token.endGroup);
- }
-
- @override
- Generator<Expression, Statement, Arguments> thisPropertyAccessGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token location,
- kernel.Name name,
- kernel.Member getter,
- kernel.Member setter) {
- // TODO(brianwilkerson) Figure out how to get the token for the name.
- return new AnalyzerThisPropertyAccessGenerator(
- helper, astFactory, location, name, getter, setter);
- }
-
- @override
- Expression throwExpression(Token throwKeyword, Expression expression) =>
- astFactory.throwExpression(throwKeyword, expression);
-
- @override
- Statement tryStatement(
- Token tryKeyword,
- Statement body,
- List<CatchClause> catchClauses,
- Token finallyKeyword,
- Statement finallyBlock) =>
- astFactory.tryStatement(
- tryKeyword, body, catchClauses, finallyKeyword, finallyBlock);
-
- @override
- Generator<Expression, Statement, Arguments> typeUseGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- PrefixBuilder prefix,
- int declarationReferenceOffset,
- TypeDeclarationBuilder declaration,
- String plainNameForRead) {
- return new AnalyzerTypeUseGenerator(helper, astFactory, token, prefix,
- declarationReferenceOffset, declaration, plainNameForRead);
- }
-
- @override
- Generator<Expression, Statement, Arguments> unlinkedGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- UnlinkedDeclaration declaration) {
- return new AnalyzerUnlinkedNameGenerator(
- helper, astFactory, token, declaration);
- }
-
- @override
- Generator<Expression, Statement, Arguments> unresolvedNameGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- kernel.Name name) {
- return new AnalyzerUnresolvedNameGenerator(helper, astFactory, token, name);
- }
-
- @override
- VariableDeclarationStatement variablesDeclaration(
- List<VariableDeclaration> declarations, Uri uri) {
- // TODO(brianwilkerson) Implement this.
- throw new UnimplementedError();
- }
-
- @override
- NodeList<VariableDeclaration> variablesDeclarationExtractDeclarations(
- VariableDeclarationStatement variablesDeclaration) =>
- variablesDeclaration.variables.variables;
-
- @override
- Generator<Expression, Statement, Arguments> variableUseGenerator(
- ExpressionGeneratorHelper<Expression, Statement, Arguments> helper,
- Token token,
- VariableDeclarationStatement variable,
- kernel.DartType promotedType) {
- return new AnalyzerVariableUseGenerator(helper, astFactory, token);
- }
-
- Statement whileStatement(Token whileKeyword,
- ParenthesizedExpression condition, Statement body) =>
- astFactory.whileStatement(whileKeyword, condition.leftParenthesis,
- condition.expression, condition.rightParenthesis, body);
-
- @override
- Statement wrapVariables(Statement statement) => statement;
-
- @override
- Statement yieldStatement(Token yieldKeyword, Token star,
- Expression expression, Token semicolon) =>
- astFactory.yieldStatement(yieldKeyword, star, expression, semicolon);
-}
diff --git a/pkg/analyzer/lib/src/fasta/resolution_applier.dart b/pkg/analyzer/lib/src/fasta/resolution_applier.dart
index 5aa09cd..9d1b45c 100644
--- a/pkg/analyzer/lib/src/fasta/resolution_applier.dart
+++ b/pkg/analyzer/lib/src/fasta/resolution_applier.dart
@@ -280,7 +280,7 @@
_typeContext.enterLocalFunction(element);
functionExpression.body?.accept(this);
- _storeFunctionType(_get(node).inferredType, element);
+ _storeFunctionType(_get(node.name).inferredType, element);
// Associate the elements with the nodes.
if (element != null) {
diff --git a/pkg/analyzer/lib/src/fasta/resolution_storer.dart b/pkg/analyzer/lib/src/fasta/resolution_storer.dart
index 3713e55..e0b2de8 100644
--- a/pkg/analyzer/lib/src/fasta/resolution_storer.dart
+++ b/pkg/analyzer/lib/src/fasta/resolution_storer.dart
@@ -3,8 +3,10 @@
// BSD-style license that can be found in the LICENSE file.
import 'package:analyzer/src/fasta/resolution_applier.dart';
+import 'package:front_end/src/fasta/kernel/factory.dart';
import 'package:front_end/src/fasta/kernel/kernel_shadow_ast.dart';
import 'package:front_end/src/fasta/type_inference/type_inference_listener.dart';
+import 'package:front_end/src/scanner/token.dart';
import 'package:kernel/ast.dart';
import 'package:kernel/type_algebra.dart';
@@ -39,7 +41,10 @@
/// Type inference listener that records inferred types for later use by
/// [ResolutionApplier].
-class ResolutionStorer extends _ResolutionStorer<int, int, Node, int> {
+class ResolutionStorer extends _ResolutionStorer<int, int, Node, int>
+ implements
+ TypeInferenceListener<int, int, Node, int>,
+ Factory<void, void, void, void> {
ResolutionStorer(Map<int, ResolutionData<DartType, int, Node, int>> data)
: super(data);
}
@@ -48,9 +53,7 @@
/// accidentally peeking into kernel internals.
///
/// TODO(paulberry): when the time is right, fuse this with [ResolutionStorer].
-class _ResolutionStorer<Location, Declaration, Reference, PrefixInfo>
- implements
- TypeInferenceListener<Location, Declaration, Reference, PrefixInfo> {
+class _ResolutionStorer<Location, Declaration, Reference, PrefixInfo> {
final Map<Location,
ResolutionData<DartType, Declaration, Reference, PrefixInfo>> _data;
@@ -92,35 +95,56 @@
_data.remove(location) == null;
}
- @override
void asExpression(
- ExpressionJudgment judgment, Location location, DartType inferredType) {
+ ExpressionJudgment judgment,
+ Location location,
+ void expression,
+ Token asOperator,
+ void literalType,
+ DartType inferredType) {
_store(location, literalType: inferredType, inferredType: inferredType);
}
- @override
- void assertInitializer(InitializerJudgment judgment, Location location) {}
+ void assertInitializer(
+ InitializerJudgment judgment,
+ Location location,
+ Token assertKeyword,
+ Token leftParenthesis,
+ void condition,
+ Token comma,
+ void message,
+ Token rightParenthesis) {}
- @override
- void assertStatement(StatementJudgment judgment, Location location) {}
+ void assertStatement(
+ StatementJudgment judgment,
+ Location location,
+ Token assertKeyword,
+ Token leftParenthesis,
+ void condition,
+ Token comma,
+ void message,
+ Token rightParenthesis,
+ Token semicolon) {}
- @override
void awaitExpression(ExpressionJudgment judgment, Location location,
- DartType inferredType) =>
+ Token awaitKeyword, void expression, DartType inferredType) =>
genericExpression("awaitExpression", location, inferredType);
- @override
- void block(StatementJudgment judgment, Location location) {}
+ void block(StatementJudgment judgment, Location location, Token leftBracket,
+ List<void> statements, Token rightBracket) {}
- @override
void boolLiteral(ExpressionJudgment judgment, Location location,
- DartType inferredType) =>
+ Token literal, bool value, DartType inferredType) =>
genericExpression("boolLiteral", location, inferredType);
- @override
- void breakStatement(StatementJudgment judgment, Location location) {}
+ void breakStatement(
+ StatementJudgment judgment,
+ Location location,
+ Token breakKeyword,
+ void label,
+ Token semicolon,
+ covariant Object labelBinder) {}
- @override
void cascadeExpression(
ExpressionJudgment judgment, Location location, DartType inferredType) {
// Overridden so that the type of the expression will not be recorded. We
@@ -129,32 +153,47 @@
// correctly apply the type even if we recorded it.
}
- @override
void catchStatement(
Catch judgment,
Location location,
+ Token onKeyword,
+ void type,
+ Token catchKeyword,
+ Token leftParenthesis,
+ Token exceptionParameter,
+ Token comma,
+ Token stackTraceParameter,
+ Token rightParenthesis,
+ void body,
DartType guardType,
- Location exceptionLocation,
+ covariant VariableDeclarationBinder exceptionBinder,
DartType exceptionType,
- Location stackTraceLocation,
+ covariant VariableDeclarationBinder stackTraceBinder,
DartType stackTraceType) {
_store(location, literalType: guardType);
- if (exceptionLocation != null) {
- _store(exceptionLocation, literalType: exceptionType);
+ if (exceptionBinder != null) {
+ _store(exceptionBinder.fileOffset as Location,
+ literalType: exceptionType);
}
- if (stackTraceLocation != null) {
- _store(stackTraceLocation, literalType: stackTraceType);
+ if (stackTraceBinder != null) {
+ _store(stackTraceBinder.fileOffset as Location,
+ literalType: stackTraceType);
}
}
- @override
- void conditionalExpression(ExpressionJudgment judgment, Location location,
+ void conditionalExpression(
+ ExpressionJudgment judgment,
+ Location location,
+ void condition,
+ Token question,
+ void thenExpression,
+ Token colon,
+ void elseExpression,
DartType inferredType) =>
genericExpression("conditionalExpression", location, inferredType);
- @override
void constructorInvocation(ExpressionJudgment judgment, Location location,
Reference expressionTarget, DartType inferredType) {
// A class reference may have already been stored at this location by
@@ -164,43 +203,79 @@
_store(location, inferredType: inferredType, reference: expressionTarget);
}
- @override
- void continueSwitchStatement(StatementJudgment judgment, Location location) {}
+ void continueStatement(
+ StatementJudgment judgment,
+ Location location,
+ Token continueKeyword,
+ void label,
+ Token semicolon,
+ covariant Object labelBinder) {}
- @override
+ void continueSwitchStatement(
+ StatementJudgment judgment,
+ Location location,
+ Token continueKeyword,
+ void label,
+ Token semicolon,
+ covariant Object labelBinder) {}
+
void deferredCheck(ExpressionJudgment judgment, Location location,
DartType inferredType) =>
genericExpression("deferredCheck", location, inferredType);
- @override
- void doStatement(StatementJudgment judgment, Location location) {}
+ void doStatement(
+ StatementJudgment judgment,
+ Location location,
+ Token doKeyword,
+ void body,
+ Token whileKeyword,
+ Token leftParenthesis,
+ void condition,
+ Token rightParenthesis,
+ Token semicolon) {}
- @override
void doubleLiteral(ExpressionJudgment judgment, Location location,
- DartType inferredType) =>
+ Token literal, double value, DartType inferredType) =>
genericExpression("doubleLiteral", location, inferredType);
- @override
- void expressionStatement(StatementJudgment judgment, Location location) {}
+ void emptyStatement(Token semicolon) {}
- @override
- void fieldInitializer(InitializerJudgment judgment, Location location,
+ void expressionStatement(StatementJudgment judgment, Location location,
+ void expression, Token semicolon) {}
+
+ void fieldInitializer(
+ InitializerJudgment judgment,
+ Location location,
+ Token thisKeyword,
+ Token period,
+ Token fieldName,
+ Token equals,
+ void expression,
Reference initializerField) {
_store(location, reference: initializerField);
}
- @override
void forInStatement(
StatementJudgment judgment,
Location location,
- Location variableLocation,
- DartType variableType,
+ Token awaitKeyword,
+ Token forKeyword,
+ Token leftParenthesis,
+ Object loopVariable,
+ Token identifier,
+ Token inKeyword,
+ void iterator,
+ Token rightParenthesis,
+ void body,
+ covariant VariableDeclarationBinder loopVariableBinder,
+ DartType loopVariableType,
Location writeLocation,
DartType writeType,
Declaration writeVariable,
Reference writeTarget) {
- if (variableLocation != null) {
- _store(variableLocation, inferredType: variableType);
+ if (loopVariableBinder != null) {
+ _store(loopVariableBinder.fileOffset as Location,
+ inferredType: loopVariableType);
} else {
if (writeVariable != null) {
_store(writeLocation,
@@ -214,16 +289,30 @@
}
}
- @override
- void forStatement(StatementJudgment judgment, Location location) {}
+ void forStatement(
+ StatementJudgment judgment,
+ Location location,
+ Token forKeyword,
+ Token leftParenthesis,
+ void variableDeclarationList,
+ void initialization,
+ Token leftSeparator,
+ void condition,
+ Token rightSeparator,
+ void updaters,
+ Token rightParenthesis,
+ void body) {}
- @override
- void functionDeclaration(StatementJudgment judgment, Location location,
- FunctionType inferredType) {
- _store(location, inferredType: inferredType);
+ void functionDeclaration(
+ covariant VariableDeclarationBinder binder, FunctionType inferredType) {
+ _store(binder.fileOffset as Location, inferredType: inferredType);
}
- @override
+ Object binderForFunctionDeclaration(
+ StatementJudgment judgment, int fileOffset, String name) {
+ return new VariableDeclarationBinder(fileOffset);
+ }
+
void functionExpression(ExpressionJudgment judgment, Location location,
DartType inferredType) =>
genericExpression("functionExpression", location, inferredType);
@@ -233,76 +322,114 @@
_store(location, inferredType: inferredType);
}
- @override
- void ifNull(ExpressionJudgment judgment, Location location,
- DartType inferredType) =>
+ void ifNull(ExpressionJudgment judgment, Location location, void leftOperand,
+ Token operator, void rightOperand, DartType inferredType) =>
genericExpression('ifNull', location, inferredType);
- @override
- void ifStatement(StatementJudgment judgment, Location location) {}
+ void ifStatement(
+ StatementJudgment judgment,
+ Location location,
+ Token ifKeyword,
+ Token leftParenthesis,
+ void condition,
+ Token rightParenthesis,
+ void thenStatement,
+ Token elseKeyword,
+ void elseStatement) {}
- @override
- void intLiteral(ExpressionJudgment judgment, Location location,
- DartType inferredType) =>
+ void intLiteral(ExpressionJudgment judgment, Location location, Token literal,
+ num value, DartType inferredType) =>
genericExpression("intLiteral", location, inferredType);
- @override
void invalidInitializer(InitializerJudgment judgment, Location location) {}
- @override
- void labeledStatement(StatementJudgment judgment, Location location) {}
+ void labeledStatement(List<Object> labels, void statement) {}
- @override
- void listLiteral(ExpressionJudgment judgment, Location location,
+ void statementLabel(covariant void binder, Token label, Token colon) {}
+
+ void binderForStatementLabel(
+ StatementJudgment judgment, int fileOffset, String name) {}
+
+ void listLiteral(
+ ExpressionJudgment judgment,
+ Location location,
+ Token constKeyword,
+ Object typeArguments,
+ Token leftBracket,
+ void elements,
+ Token rightBracket,
DartType inferredType) =>
genericExpression("listLiteral", location, inferredType);
- @override
- void logicalExpression(ExpressionJudgment judgment, Location location,
+ void logicalExpression(
+ ExpressionJudgment judgment,
+ Location location,
+ void leftOperand,
+ Token operator,
+ void rightOperand,
DartType inferredType) =>
genericExpression("logicalExpression", location, inferredType);
- @override
- void mapLiteral(ExpressionJudgment judgment, Location location,
- DartType typeContext) =>
- genericExpression("mapLiteral", location, typeContext);
-
- @override
- void namedFunctionExpression(ExpressionJudgment judgment, Location location,
+ void mapLiteral(
+ ExpressionJudgment judgment,
+ Location location,
+ Token constKeyword,
+ Object typeArguments,
+ Token leftBracket,
+ List<Object> entries,
+ Token rightBracket,
DartType inferredType) =>
- genericExpression("namedFunctionExpression", location, inferredType);
+ genericExpression("mapLiteral", location, inferredType);
- @override
- void not(ExpressionJudgment judgment, Location location,
- DartType inferredType) =>
+ void mapLiteralEntry(
+ Object judgment, int fileOffset, void key, Token separator, void value) {
+ // TODO(brianwilkerson) Implement this.
+ }
+
+ void namedFunctionExpression(ExpressionJudgment judgment,
+ covariant VariableDeclarationBinder binder, DartType inferredType) =>
+ genericExpression("namedFunctionExpression",
+ binder.fileOffset as Location, inferredType);
+
+ void not(ExpressionJudgment judgment, Location location, Token operator,
+ void operand, DartType inferredType) =>
genericExpression("not", location, inferredType);
- @override
void nullLiteral(ExpressionJudgment judgment, Location location,
- bool isSynthetic, DartType inferredType) {
+ Token literal, bool isSynthetic, DartType inferredType) {
if (isSynthetic) return null;
genericExpression("nullLiteral", location, inferredType);
}
- @override
void indexAssign(ExpressionJudgment judgment, Location location,
Reference writeMember, Reference combiner, DartType inferredType) {
_store(location,
reference: writeMember, inferredType: inferredType, combiner: combiner);
}
- @override
- void isExpression(ExpressionJudgment judgment, Location location,
- DartType testedType, DartType inferredType) {
+ void isExpression(
+ ExpressionJudgment judgment,
+ Location location,
+ void expression,
+ Token isOperator,
+ void literalType,
+ DartType testedType,
+ DartType inferredType) {
_store(location, literalType: testedType, inferredType: inferredType);
}
- void isNotExpression(ExpressionJudgment judgment, Location location,
- DartType type, DartType inferredType) {
+ void isNotExpression(
+ ExpressionJudgment judgment,
+ Location location,
+ void expression,
+ Token isOperator,
+ Token notOperator,
+ void literalType,
+ DartType type,
+ DartType inferredType) {
_store(location, literalType: type, inferredType: inferredType);
}
- @override
void methodInvocation(
ExpressionJudgment judgment,
Location resultOffset,
@@ -324,7 +451,6 @@
reference: interfaceMember);
}
- @override
void methodInvocationCall(
ExpressionJudgment judgment,
Location resultOffset,
@@ -344,7 +470,6 @@
isImplicitCall: isImplicitCall);
}
- @override
void propertyAssign(
ExpressionJudgment judgment,
Location location,
@@ -360,38 +485,38 @@
inferredType: inferredType);
}
- @override
void propertySet(ExpressionJudgment judgment, Location location,
DartType inferredType) =>
genericExpression("propertySet", location, inferredType);
- @override
void propertyGet(ExpressionJudgment judgment, Location location,
Reference member, DartType inferredType) {
_store(location, reference: member, inferredType: inferredType);
}
- @override
void propertyGetCall(
ExpressionJudgment judgment, Location location, DartType inferredType) {
_store(location, isExplicitCall: true);
}
- @override
- void redirectingInitializer(InitializerJudgment judgment, Location location,
+ void redirectingInitializer(
+ InitializerJudgment judgment,
+ Location location,
+ Token thisKeyword,
+ Token period,
+ Token constructorName,
+ covariant Object argumentList,
Reference initializerTarget) {
_store(location, reference: initializerTarget);
}
- @override
void rethrow_(ExpressionJudgment judgment, Location location,
- DartType inferredType) =>
+ Token rethrowKeyword, DartType inferredType) =>
genericExpression('rethrow', location, inferredType);
- @override
- void returnStatement(StatementJudgment judgment, Location location) {}
+ void returnStatement(StatementJudgment judgment, Location location,
+ Token returnKeyword, void expression, Token semicolon) {}
- @override
void staticAssign(
ExpressionJudgment judgment,
Location location,
@@ -407,13 +532,11 @@
inferredType: inferredType);
}
- @override
void staticGet(ExpressionJudgment judgment, Location location,
Reference expressionTarget, DartType inferredType) {
_store(location, reference: expressionTarget, inferredType: inferredType);
}
- @override
void staticInvocation(
ExpressionJudgment judgment,
Location location,
@@ -432,50 +555,75 @@
inferredType: inferredType);
}
- @override
void stringConcatenation(
ExpressionJudgment judgment, Location location, DartType inferredType) {
// We don't need the type - we already know that it is String.
// Moreover, the file offset for StringConcatenation is `-1`.
}
- @override
void stringLiteral(ExpressionJudgment judgment, Location location,
- DartType inferredType) =>
+ Token literal, String value, DartType inferredType) =>
genericExpression("StringLiteral", location, inferredType);
- @override
- void superInitializer(InitializerJudgment judgment, Location location) {}
+ void superInitializer(
+ InitializerJudgment judgment,
+ Location location,
+ Token superKeyword,
+ Token period,
+ Token constructorName,
+ covariant Object argumentList) {}
- @override
- void switchStatement(StatementJudgment judgment, Location location) {}
+ void switchCase(SwitchCaseJudgment judgment, List<Object> labels,
+ Token keyword, void expression, Token colon, List<void> statements) {}
- @override
- void symbolLiteral(ExpressionJudgment judgment, Location location,
+ void switchLabel(covariant void binder, Token label, Token colon) {}
+
+ void binderForSwitchLabel(
+ SwitchCaseJudgment judgment, int fileOffset, String name) {}
+
+ void switchStatement(
+ StatementJudgment judgment,
+ Location location,
+ Token switchKeyword,
+ Token leftParenthesis,
+ void expression,
+ Token rightParenthesis,
+ Token leftBracket,
+ void members,
+ Token rightBracket) {}
+
+ void symbolLiteral(
+ ExpressionJudgment judgment,
+ Location location,
+ Token poundSign,
+ List<Token> components,
+ String value,
DartType inferredType) =>
genericExpression("symbolLiteral", location, inferredType);
- @override
- void thisExpression(
- ExpressionJudgment judgment, Location location, DartType inferredType) {}
+ void thisExpression(ExpressionJudgment judgment, Location location,
+ Token thisKeyword, DartType inferredType) {}
- @override
void throw_(ExpressionJudgment judgment, Location location,
- DartType inferredType) =>
+ Token throwKeyword, void expression, DartType inferredType) =>
genericExpression('throw', location, inferredType);
- @override
void tryCatch(StatementJudgment judgment, Location location) {}
- @override
- void tryFinally(StatementJudgment judgment, Location location) {}
+ void tryFinally(
+ StatementJudgment judgment,
+ Location location,
+ Token tryKeyword,
+ void body,
+ void catchClauses,
+ Token finallyKeyword,
+ void finallyBlock) {}
void typeLiteral(ExpressionJudgment judgment, Location location,
Reference expressionType, DartType inferredType) {
_store(location, reference: expressionType, inferredType: inferredType);
}
- @override
void variableAssign(
ExpressionJudgment judgment,
Location location,
@@ -491,39 +639,47 @@
inferredType: inferredType);
}
- @override
- void variableDeclaration(StatementJudgment judgment, Location location,
+ void variableDeclaration(covariant VariableDeclarationBinder binder,
DartType statementType, DartType inferredType) {
- _store(location, literalType: statementType, inferredType: inferredType);
+ _store(binder.fileOffset as Location,
+ literalType: statementType, inferredType: inferredType);
}
- @override
- void variableGet(ExpressionJudgment judgment, Location location,
- bool isInCascade, Declaration expressionVariable, DartType inferredType) {
+ Object binderForVariableDeclaration(
+ StatementJudgment judgment, int fileOffset, String name) {
+ return new VariableDeclarationBinder(fileOffset);
+ }
+
+ void variableGet(
+ ExpressionJudgment judgment,
+ Location location,
+ bool isInCascade,
+ covariant VariableDeclarationBinder variableBinder,
+ DartType inferredType) {
if (isInCascade) {
return;
}
_store(location,
- declaration: expressionVariable, inferredType: inferredType);
+ declaration: variableBinder.fileOffset as Declaration,
+ inferredType: inferredType);
}
- @override
- void variableSet(ExpressionJudgment judgment, Location location,
- DartType inferredType) =>
- genericExpression("variableSet", location, inferredType);
+ void whileStatement(
+ StatementJudgment judgment,
+ Location location,
+ Token whileKeyword,
+ Token leftParenthesis,
+ void condition,
+ Token rightParenthesis,
+ void body) {}
- @override
- void whileStatement(StatementJudgment judgment, Location location) {}
+ void yieldStatement(StatementJudgment judgment, Location location,
+ Token yieldKeyword, Token star, void expression, Token semicolon) {}
- @override
- void yieldStatement(StatementJudgment judgment, Location location) {}
-
- @override
void storePrefixInfo(Location location, PrefixInfo prefixInfo) {
_store(location, prefixInfo: prefixInfo);
}
- @override
void storeClassReference(
Location location, Reference reference, DartType rawType) {
// TODO(paulberry): would it be better to use literalType?
@@ -531,6 +687,13 @@
}
}
+/// TODO(paulberry): eventually just use the element directly.
+class VariableDeclarationBinder {
+ final int fileOffset;
+
+ VariableDeclarationBinder(this.fileOffset);
+}
+
/// A [DartType] wrapper around invocation type arguments.
class TypeArgumentsDartType implements DartType {
final List<DartType> types;
diff --git a/pkg/analyzer/lib/src/generated/error_verifier.dart b/pkg/analyzer/lib/src/generated/error_verifier.dart
index 204542e..b470ac2 100644
--- a/pkg/analyzer/lib/src/generated/error_verifier.dart
+++ b/pkg/analyzer/lib/src/generated/error_verifier.dart
@@ -1239,6 +1239,7 @@
_checkForTypeParameterSupertypeOfItsBound(node);
_checkForTypeAnnotationDeferredClass(node.bound);
_checkForImplicitDynamicType(node.bound);
+ _checkForGenericFunctionType(node.bound);
if (_options.strongMode) node.bound?.accept(_uninstantiatedBoundChecker);
return super.visitTypeParameter(node);
}
@@ -4183,6 +4184,19 @@
}
}
+ void _checkForGenericFunctionType(TypeAnnotation node) {
+ if (node == null) {
+ return;
+ }
+ DartType type = node.type;
+ if (type is FunctionType && type.typeFormals.isNotEmpty) {
+ _errorReporter.reportErrorForNode(
+ CompileTimeErrorCode.GENERIC_FUNCTION_TYPE_CANNOT_BE_BOUND,
+ node,
+ [type]);
+ }
+ }
+
void _checkForImplicitDynamicTypedLiteral(TypedLiteral node) {
if (_options.implicitDynamic || node.typeArguments != null) {
return;
@@ -5905,7 +5919,9 @@
* Verify that the type arguments in the given [typeName] are all within
* their bounds.
*
- * See [StaticTypeWarningCode.TYPE_ARGUMENT_NOT_MATCHING_BOUNDS].
+ * See [StaticTypeWarningCode.TYPE_ARGUMENT_NOT_MATCHING_BOUNDS],
+ * [CompileTimeErrorCode.TYPE_ARGUMENT_NOT_MATCHING_BOUNDS],
+ * [CompileTimeErrorCode.GENERIC_FUNCTION_CANNOT_BE_BOUND].
*/
void _checkForTypeArgumentNotMatchingBounds(TypeName typeName) {
if (typeName.typeArguments == null) {
@@ -5931,11 +5947,19 @@
for (int i = 0; i < loopThroughIndex; i++) {
TypeAnnotation argumentNode = argumentNodes[i];
DartType argType = argumentNode.type;
+ if (argType is FunctionType && argType.typeFormals.isNotEmpty) {
+ _errorReporter.reportTypeErrorForNode(
+ CompileTimeErrorCode.GENERIC_FUNCTION_CANNOT_BE_TYPE_ARGUMENT,
+ argumentNode,
+ [argType.typeFormals.join(', ')]);
+ continue;
+ }
DartType boundType = parameterElements[i].bound;
if (argType != null && boundType != null) {
if (shouldSubstitute) {
boundType = boundType.substitute2(arguments, parameterTypes);
}
+
if (!_typeSystem.isSubtypeOf(argType, boundType)) {
ErrorCode errorCode;
if (_isInConstInstanceCreation) {
@@ -6455,6 +6479,15 @@
// <T extends Clonable<T>>
//
DartType argType = typeArgs[i];
+
+ if (argType is FunctionType && argType.typeFormals.isNotEmpty) {
+ _errorReporter.reportTypeErrorForNode(
+ CompileTimeErrorCode.GENERIC_FUNCTION_CANNOT_BE_TYPE_ARGUMENT,
+ typeArgumentList[i],
+ [argType.typeFormals.join(', ')]);
+ continue;
+ }
+
DartType bound =
fnTypeParams[i].bound.substitute2(typeArgs, fnTypeParams);
if (!_typeSystem.isSubtypeOf(argType, bound)) {
diff --git a/pkg/analyzer/lib/src/generated/parser_fasta.dart b/pkg/analyzer/lib/src/generated/parser_fasta.dart
index 6f5e77a..43b4191 100644
--- a/pkg/analyzer/lib/src/generated/parser_fasta.dart
+++ b/pkg/analyzer/lib/src/generated/parser_fasta.dart
@@ -283,8 +283,10 @@
@override
TypeAnnotation parseTypeAnnotation(bool inExpression) {
- currentToken = fastaParser
- .parseType(fastaParser.syntheticPreviousToken(currentToken))
+ Token previous = fastaParser.syntheticPreviousToken(currentToken);
+ currentToken = fasta
+ .computeType(previous, true, !inExpression)
+ .parseType(previous, fastaParser)
.next;
return astBuilder.pop();
}
@@ -301,8 +303,10 @@
@override
TypeName parseTypeName(bool inExpression) {
- currentToken = fastaParser
- .parseType(fastaParser.syntheticPreviousToken(currentToken))
+ Token previous = fastaParser.syntheticPreviousToken(currentToken);
+ currentToken = fasta
+ .computeType(previous, true, !inExpression)
+ .parseType(previous, fastaParser)
.next;
return astBuilder.pop();
}
diff --git a/pkg/analyzer/lib/src/generated/resolver.dart b/pkg/analyzer/lib/src/generated/resolver.dart
index 663b76e..685704b 100644
--- a/pkg/analyzer/lib/src/generated/resolver.dart
+++ b/pkg/analyzer/lib/src/generated/resolver.dart
@@ -9043,7 +9043,10 @@
TypeNameResolver typeNameResolver = null;
TypeParameterBoundsResolver(
- this.typeSystem, this.library, this.source, this.errorListener);
+ this.typeSystem, this.library, this.source, this.errorListener)
+ : libraryScope = new LibraryScope(library),
+ typeNameResolver = new TypeNameResolver(typeSystem,
+ typeSystem.typeProvider, library, source, errorListener);
/**
* Resolve bounds of type parameters of classes, class and function type
@@ -9070,27 +9073,40 @@
typeNameResolver.resolveTypeName(type);
// TODO(scheglov) report error when don't apply type bounds for type bounds
} else if (type is GenericFunctionType) {
- void resolveTypeParameter(TypeParameter t) {
- _resolveTypeName(t.bound);
- }
+ // While GenericFunctionTypes with free types are not allowed as bounds,
+ // those free types *should* ideally be recognized as type parameter types
+ // rather than classnames. Create a scope to accomplish that.
+ Scope previousScope = typeNameResolver.nameScope;
- void resolveParameter(FormalParameter p) {
- if (p is SimpleFormalParameter) {
- _resolveTypeName(p.type);
- } else if (p is DefaultFormalParameter) {
- resolveParameter(p.parameter);
- } else if (p is FieldFormalParameter) {
- _resolveTypeName(p.type);
- } else if (p is FunctionTypedFormalParameter) {
- _resolveTypeName(p.returnType);
- p.typeParameters?.typeParameters?.forEach(resolveTypeParameter);
- p.parameters?.parameters?.forEach(resolveParameter);
+ try {
+ Scope typeParametersScope = new TypeParameterScope(
+ typeNameResolver.nameScope, type.type.element);
+ typeNameResolver.nameScope = typeParametersScope;
+
+ void resolveTypeParameter(TypeParameter t) {
+ _resolveTypeName(t.bound);
}
- }
- _resolveTypeName(type.returnType);
- type.typeParameters?.typeParameters?.forEach(resolveTypeParameter);
- type.parameters?.parameters?.forEach(resolveParameter);
+ void resolveParameter(FormalParameter p) {
+ if (p is SimpleFormalParameter) {
+ _resolveTypeName(p.type);
+ } else if (p is DefaultFormalParameter) {
+ resolveParameter(p.parameter);
+ } else if (p is FieldFormalParameter) {
+ _resolveTypeName(p.type);
+ } else if (p is FunctionTypedFormalParameter) {
+ _resolveTypeName(p.returnType);
+ p.typeParameters?.typeParameters?.forEach(resolveTypeParameter);
+ p.parameters?.parameters?.forEach(resolveParameter);
+ }
+ }
+
+ _resolveTypeName(type.returnType);
+ type.typeParameters?.typeParameters?.forEach(resolveTypeParameter);
+ type.parameters?.parameters?.forEach(resolveParameter);
+ } finally {
+ typeNameResolver.nameScope = previousScope;
+ }
}
}
@@ -9111,10 +9127,10 @@
bound.type = typeParameterElement.bound;
}
} else {
- libraryScope ??= new LibraryScope(library);
typeParametersScope ??= createTypeParametersScope();
- typeNameResolver ??= new TypeNameResolver(typeSystem,
- typeSystem.typeProvider, library, source, errorListener);
+ // _resolveTypeParameters is the entry point into each declaration
+ // with a separate scope. We can safely, and should, clobber the
+ // old scope here.
typeNameResolver.nameScope = typeParametersScope;
_resolveTypeName(bound);
typeParameterElement.bound = bound.type;
diff --git a/pkg/analyzer/lib/src/generated/type_system.dart b/pkg/analyzer/lib/src/generated/type_system.dart
index e54318a..a500975 100644
--- a/pkg/analyzer/lib/src/generated/type_system.dart
+++ b/pkg/analyzer/lib/src/generated/type_system.dart
@@ -15,7 +15,8 @@
import 'package:analyzer/src/dart/element/element.dart';
import 'package:analyzer/src/dart/element/member.dart' show TypeParameterMember;
import 'package:analyzer/src/dart/element/type.dart';
-import 'package:analyzer/src/error/codes.dart' show StrongModeCode;
+import 'package:analyzer/src/error/codes.dart'
+ show StrongModeCode, CompileTimeErrorCode;
import 'package:analyzer/src/generated/engine.dart'
show AnalysisContext, AnalysisOptionsImpl;
import 'package:analyzer/src/generated/resolver.dart' show TypeProvider;
diff --git a/pkg/analyzer/test/generated/checked_mode_compile_time_error_code_kernel_test.dart b/pkg/analyzer/test/generated/checked_mode_compile_time_error_code_kernel_test.dart
index 171376f..6cd4ceb 100644
--- a/pkg/analyzer/test/generated/checked_mode_compile_time_error_code_kernel_test.dart
+++ b/pkg/analyzer/test/generated/checked_mode_compile_time_error_code_kernel_test.dart
@@ -149,13 +149,6 @@
@failingTest
@override
- test_fieldTypeOk_generic() async {
- // UnimplementedError: kernel: (Let) let final dynamic #t4 = #lib2::y in let ...
- await super.test_fieldTypeOk_generic();
- }
-
- @failingTest
- @override
test_fieldTypeOk_unresolved_null() async {
// UnimplementedError: kernel: (AsExpression) x as{TypeError} invalid-type
await super.test_fieldTypeOk_unresolved_null();
diff --git a/pkg/analyzer/test/generated/compile_time_error_code_kernel_test.dart b/pkg/analyzer/test/generated/compile_time_error_code_kernel_test.dart
index 4d9b603..97fa300 100644
--- a/pkg/analyzer/test/generated/compile_time_error_code_kernel_test.dart
+++ b/pkg/analyzer/test/generated/compile_time_error_code_kernel_test.dart
@@ -526,16 +526,16 @@
@override
@failingTest
- test_constWithNonConst_with() async {
- // Bad state: No type information for C at 72
- await super.test_constWithNonConst_with();
+ test_constWithNonConst_in_const_context() async {
+ // Bad state: No data for () at 58
+ await super.test_constWithNonConst_in_const_context();
}
@override
@failingTest
- test_constWithNonConst_in_const_context() async {
- // Bad state: No data for () at 58
- await super.test_constWithNonConst_in_const_context();
+ test_constWithNonConst_with() async {
+ // Bad state: No type information for C at 72
+ await super.test_constWithNonConst_with();
}
@override
@@ -3098,6 +3098,69 @@
// Test passes, even though if fails in the superclass
await super.test_yieldInNonGenerator_async();
}
+
+ @override
+ @failingTest
+ @potentialAnalyzerProblem
+ test_genericFunctionTypeAsBound_class() async {
+ await super.test_genericFunctionTypeAsBound_class();
+ }
+
+ @override
+ @failingTest
+ @potentialAnalyzerProblem
+ test_genericFunctionTypeAsBound_genericFunction() async {
+ await super.test_genericFunctionTypeAsBound_genericFunction();
+ }
+
+ @override
+ @failingTest
+ @potentialAnalyzerProblem
+ test_genericFunctionTypeAsBound_genericFunctionTypedef() async {
+ await super.test_genericFunctionTypeAsBound_genericFunctionTypedef();
+ }
+
+ @override
+ @failingTest
+ @potentialAnalyzerProblem
+ test_genericFunctionTypeAsBound_parameterOfFunction() async {
+ await super.test_genericFunctionTypeAsBound_parameterOfFunction();
+ }
+
+ @override
+ @failingTest
+ @potentialAnalyzerProblem
+ test_genericFunctionTypeAsBound_typedef() async {
+ await super.test_genericFunctionTypeAsBound_typedef();
+ }
+
+ @override
+ @failingTest
+ @potentialAnalyzerProblem
+ test_genericFunctionTypeArgument_class() async {
+ await super.test_genericFunctionTypeArgument_class();
+ }
+
+ @override
+ @failingTest
+ @potentialAnalyzerProblem
+ test_genericFunctionTypeArgument_functionType() async {
+ await super.test_genericFunctionTypeArgument_functionType();
+ }
+
+ @override
+ @failingTest
+ @potentialAnalyzerProblem
+ test_genericFunctionTypeArgument_function() async {
+ await super.test_genericFunctionTypeArgument_function();
+ }
+
+ @override
+ @failingTest
+ @potentialAnalyzerProblem
+ test_genericFunctionTypeArgument_method() async {
+ await super.test_genericFunctionTypeArgument_method();
+ }
}
/// Tests marked with this annotation fail because of a Fasta problem.
diff --git a/pkg/analyzer/test/generated/compile_time_error_code_test.dart b/pkg/analyzer/test/generated/compile_time_error_code_test.dart
index 6923bc6..6f250b2 100644
--- a/pkg/analyzer/test/generated/compile_time_error_code_test.dart
+++ b/pkg/analyzer/test/generated/compile_time_error_code_test.dart
@@ -2749,6 +2749,55 @@
verify([source]);
}
+ test_genericFunctionTypeAsBound_class() async {
+ Source source = addSource(r'''
+class C<T extends S Function<S>(S)> {
+}''');
+ await computeAnalysisResult(source);
+ assertErrors(
+ source, [CompileTimeErrorCode.GENERIC_FUNCTION_TYPE_CANNOT_BE_BOUND]);
+ verify([source]);
+ }
+
+ test_genericFunctionTypeAsBound_genericFunction() async {
+ Source source = addSource(r'''
+T Function<T extends S Function<S>(S)>(T) fun;
+''');
+ await computeAnalysisResult(source);
+ assertErrors(
+ source, [CompileTimeErrorCode.GENERIC_FUNCTION_TYPE_CANNOT_BE_BOUND]);
+ verify([source]);
+ }
+
+ test_genericFunctionTypeAsBound_genericFunctionTypedef() async {
+ Source source = addSource(r'''
+typedef foo = T Function<T extends S Function<S>(S)>(T t);
+''');
+ await computeAnalysisResult(source);
+ assertErrors(
+ source, [CompileTimeErrorCode.GENERIC_FUNCTION_TYPE_CANNOT_BE_BOUND]);
+ verify([source]);
+ }
+
+ test_genericFunctionTypeAsBound_parameterOfFunction() async {
+ Source source = addSource(r'''
+class C<T extends void Function(S Function<S>(S))> {
+}''');
+ await computeAnalysisResult(source);
+ assertNoErrors(source);
+ verify([source]);
+ }
+
+ test_genericFunctionTypeAsBound_typedef() async {
+ Source source = addSource(r'''
+typedef T foo<T extends S Function<S>(S)>(T t);
+''');
+ await computeAnalysisResult(source);
+ assertErrors(
+ source, [CompileTimeErrorCode.GENERIC_FUNCTION_TYPE_CANNOT_BE_BOUND]);
+ verify([source]);
+ }
+
test_genericFunctionTypedParameter() async {
// Once dartbug.com/28515 is fixed, this syntax should no longer generate an
// error.
@@ -7014,6 +7063,98 @@
verify([source]);
}
+ test_genericFunctionTypeArgument_class() async {
+ Source source = addSource(r'''
+class C<T> {}
+C<T Function<T>(T)> c;''');
+ await computeAnalysisResult(source);
+ assertErrors(source,
+ [CompileTimeErrorCode.GENERIC_FUNCTION_CANNOT_BE_TYPE_ARGUMENT]);
+ verify([source]);
+ }
+
+ test_genericFunctionTypeArgument_functionType() async {
+ Source source = addSource(r'''
+T Function<T>(T) f;
+main() { f<S Function<S>(S)>(null); }''');
+ await computeAnalysisResult(source);
+ assertErrors(source,
+ [CompileTimeErrorCode.GENERIC_FUNCTION_CANNOT_BE_TYPE_ARGUMENT]);
+ verify([source]);
+ }
+
+ test_genericFunctionTypeArgument_function() async {
+ Source source = addSource(r'''
+T f<T>(T) => null;
+main() { f<S Function<S>(S)>(null); }''');
+ await computeAnalysisResult(source);
+ assertErrors(source,
+ [CompileTimeErrorCode.GENERIC_FUNCTION_CANNOT_BE_TYPE_ARGUMENT]);
+ verify([source]);
+ }
+
+ test_genericFunctionTypeArgument_method() async {
+ Source source = addSource(r'''
+class C {
+ T f<T>(T) => null;
+}
+main() { new C().f<S Function<S>(S)>(null); }''');
+ await computeAnalysisResult(source);
+ assertErrors(source,
+ [CompileTimeErrorCode.GENERIC_FUNCTION_CANNOT_BE_TYPE_ARGUMENT]);
+ verify([source]);
+ }
+
+ @failingTest
+ test_genericFunctionTypeArgument_inference_functionType() async {
+ // TODO(mfairhurst) how should these inference errors be reported?
+ Source source = addSource(r'''
+T Function<T>(T) f;
+main() { f(<S>(S s) => s); }''');
+ await computeAnalysisResult(source);
+ assertErrors(source,
+ [CompileTimeErrorCode.GENERIC_FUNCTION_CANNOT_BE_TYPE_ARGUMENT]);
+ verify([source]);
+ }
+
+ @failingTest
+ test_genericFunctionTypeArgument_inference_function() async {
+ // TODO(mfairhurst) how should these inference errors be reported?
+ Source source = addSource(r'''
+T f<T>(T) => null;
+main() { f(<S>(S s) => s); }''');
+ await computeAnalysisResult(source);
+ assertErrors(source,
+ [CompileTimeErrorCode.GENERIC_FUNCTION_CANNOT_BE_TYPE_ARGUMENT]);
+ verify([source]);
+ }
+
+ @failingTest
+ test_genericFunctionTypeArgument_inference_method() async {
+ // TODO(mfairhurst) how should these inference errors be reported?
+ Source source = addSource(r'''
+class C {
+ T f<T>(T) => null;
+}
+main() { new C().f(<S>(S s) => s); }''');
+ await computeAnalysisResult(source);
+ assertErrors(source,
+ [CompileTimeErrorCode.GENERIC_FUNCTION_CANNOT_BE_TYPE_ARGUMENT]);
+ verify([source]);
+ }
+
+ @failingTest
+ test_genericFunctionTypeArgument_typedef() async {
+ // TODO(mfairhurst) diagnose these parse errors to give the correct error
+ Source source = addSource(r'''
+typedef T f<T>(T t);
+final T<Function<S>(int)> x = null;''');
+ await computeAnalysisResult(source);
+ assertErrors(source,
+ [CompileTimeErrorCode.GENERIC_FUNCTION_CANNOT_BE_TYPE_ARGUMENT]);
+ verify([source]);
+ }
+
test_undefinedAnnotation_unresolved_identifier() async {
Source source = addSource(r'''
@unresolved
diff --git a/pkg/analyzer/test/generated/error_suppression_kernel_test.dart b/pkg/analyzer/test/generated/error_suppression_kernel_test.dart
index 410dd7e..85bd5a7 100644
--- a/pkg/analyzer/test/generated/error_suppression_kernel_test.dart
+++ b/pkg/analyzer/test/generated/error_suppression_kernel_test.dart
@@ -66,41 +66,6 @@
@override
@failingTest
- test_multiple_ignores() async {
- // UnimplementedError: kernel: (Let) let final dynamic #t2 = #lib2::x in let ...
- await super.test_multiple_ignores();
- }
-
- @override
- @failingTest
- test_multiple_ignores_traling() async {
- // UnimplementedError: kernel: (Let) let final dynamic #t3 = #lib3::x in let ...
- await super.test_multiple_ignores_traling();
- }
-
- @override
- @failingTest
- test_multiple_ignores_whitespace_variant_1() async {
- // UnimplementedError: kernel: (Let) let final dynamic #t4 = #lib4::x in let ...
- await super.test_multiple_ignores_whitespace_variant_1();
- }
-
- @override
- @failingTest
- test_multiple_ignores_whitespace_variant_2() async {
- // UnimplementedError: kernel: (Let) let final dynamic #t5 = #lib5::x in let ...
- await super.test_multiple_ignores_whitespace_variant_2();
- }
-
- @override
- @failingTest
- test_multiple_ignores_whitespace_variant_3() async {
- // UnimplementedError: kernel: (Let) let final dynamic #t6 = #lib6::x in let ...
- await super.test_multiple_ignores_whitespace_variant_3();
- }
-
- @override
- @failingTest
test_no_ignores() async {
// Expected 1 errors of type StaticTypeWarningCode.INVALID_ASSIGNMENT, found 0;
// 1 errors of type CompileTimeErrorCode.CONST_INITIALIZED_WITH_NON_CONSTANT_VALUE, found 0
diff --git a/pkg/analyzer/test/generated/hint_code_kernel_test.dart b/pkg/analyzer/test/generated/hint_code_kernel_test.dart
index ad843c2..333ef36 100644
--- a/pkg/analyzer/test/generated/hint_code_kernel_test.dart
+++ b/pkg/analyzer/test/generated/hint_code_kernel_test.dart
@@ -12,6 +12,11 @@
});
}
+/// Tests marked with this annotation fail because of a Fasta problem.
+class FastaProblem {
+ const FastaProblem(String issueUri);
+}
+
@reflectiveTest
class HintCodeTest_Kernel extends HintCodeTest_Driver {
@override
@@ -69,6 +74,27 @@
return super.test_deadCode_deadFinalStatementInCase();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deadCode_statementAfterAlwaysThrowsFunction() async {
+ await super.test_deadCode_statementAfterAlwaysThrowsFunction();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deadCode_statementAfterAlwaysThrowsMethod() async {
+ await super.test_deadCode_statementAfterAlwaysThrowsMethod();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedAnnotationUse_assignment() async {
+ await super.test_deprecatedAnnotationUse_assignment();
+ }
+
@failingTest
@override
test_deprecatedAnnotationUse_call() async {
@@ -76,6 +102,13 @@
return super.test_deprecatedAnnotationUse_call();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedAnnotationUse_deprecated() async {
+ await super.test_deprecatedAnnotationUse_deprecated();
+ }
+
@failingTest
@override
test_deprecatedAnnotationUse_Deprecated() async {
@@ -85,16 +118,95 @@
@override
@failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedAnnotationUse_export() async {
+ await super.test_deprecatedAnnotationUse_export();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedAnnotationUse_field() async {
+ await super.test_deprecatedAnnotationUse_field();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedAnnotationUse_getter() async {
+ await super.test_deprecatedAnnotationUse_getter();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedAnnotationUse_import() async {
+ await super.test_deprecatedAnnotationUse_import();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedAnnotationUse_indexExpression() async {
+ await super.test_deprecatedAnnotationUse_indexExpression();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedAnnotationUse_instanceCreation() async {
+ await super.test_deprecatedAnnotationUse_instanceCreation();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedAnnotationUse_instanceCreation_namedConstructor() async {
+ await super
+ .test_deprecatedAnnotationUse_instanceCreation_namedConstructor();
+ }
+
+ @override
+ @failingTest
test_deprecatedAnnotationUse_named() async {
return super.test_deprecatedAnnotationUse_named();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedAnnotationUse_operator() async {
+ await super.test_deprecatedAnnotationUse_operator();
+ }
+
@failingTest
@override
test_deprecatedAnnotationUse_positional() async {
return super.test_deprecatedAnnotationUse_positional();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedAnnotationUse_setter() async {
+ await super.test_deprecatedAnnotationUse_setter();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedAnnotationUse_superConstructor() async {
+ await super.test_deprecatedAnnotationUse_superConstructor();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedAnnotationUse_superConstructor_namedConstructor() async {
+ await super
+ .test_deprecatedAnnotationUse_superConstructor_namedConstructor();
+ }
+
@failingTest
@override
test_deprecatedFunction_class() async {
@@ -150,6 +262,83 @@
@override
@failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_factory__expr_return_null_OK() async {
+ await super.test_factory__expr_return_null_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_factory_abstract_OK() async {
+ await super.test_factory_abstract_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_factory_bad_return() async {
+ await super.test_factory_bad_return();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_factory_block_OK() async {
+ await super.test_factory_block_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_factory_block_return_null_OK() async {
+ await super.test_factory_block_return_null_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_factory_expr_OK() async {
+ await super.test_factory_expr_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_factory_misplaced_annotation() async {
+ await super.test_factory_misplaced_annotation();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_factory_no_return_type_OK() async {
+ await super.test_factory_no_return_type_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_factory_subclass_OK() async {
+ await super.test_factory_subclass_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_factory_void_return() async {
+ await super.test_factory_void_return();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidImmutableAnnotation_method() async {
+ await super.test_invalidImmutableAnnotation_method();
+ }
+
+ @override
+ @failingTest
test_invalidRequiredParam_on_named_parameter_with_default() async {
return super.test_invalidRequiredParam_on_named_parameter_with_default();
}
@@ -181,6 +370,223 @@
@override
@failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_closure() async {
+ await super.test_invalidUseOfProtectedMember_closure();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_field() async {
+ await super.test_invalidUseOfProtectedMember_field();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_field_OK() async {
+ await super.test_invalidUseOfProtectedMember_field_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_function() async {
+ await super.test_invalidUseOfProtectedMember_function();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_function_OK() async {
+ await super.test_invalidUseOfProtectedMember_function_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_function_OK2() async {
+ await super.test_invalidUseOfProtectedMember_function_OK2();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_getter() async {
+ await super.test_invalidUseOfProtectedMember_getter();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_getter_OK() async {
+ await super.test_invalidUseOfProtectedMember_getter_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_in_docs_OK() async {
+ await super.test_invalidUseOfProtectedMember_in_docs_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_message() async {
+ await super.test_invalidUseOfProtectedMember_message();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_method_1() async {
+ await super.test_invalidUseOfProtectedMember_method_1();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_method_OK() async {
+ await super.test_invalidUseOfProtectedMember_method_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_OK_1() async {
+ await super.test_invalidUseOfProtectedMember_OK_1();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_OK_2() async {
+ await super.test_invalidUseOfProtectedMember_OK_2();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_OK_3() async {
+ await super.test_invalidUseOfProtectedMember_OK_3();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_OK_4() async {
+ await super.test_invalidUseOfProtectedMember_OK_4();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_OK_field() async {
+ await super.test_invalidUseOfProtectedMember_OK_field();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_OK_getter() async {
+ await super.test_invalidUseOfProtectedMember_OK_getter();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_OK_setter() async {
+ await super.test_invalidUseOfProtectedMember_OK_setter();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_OK_setter_2() async {
+ await super.test_invalidUseOfProtectedMember_OK_setter_2();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_setter() async {
+ await super.test_invalidUseOfProtectedMember_setter();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_setter_OK() async {
+ await super.test_invalidUseOfProtectedMember_setter_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfProtectedMember_topLevelVariable() async {
+ await super.test_invalidUseOfProtectedMember_topLevelVariable();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfVisibleForTestingMember_constructor() async {
+ await super.test_invalidUseOfVisibleForTestingMember_constructor();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfVisibleForTestingMember_method() async {
+ await super.test_invalidUseOfVisibleForTestingMember_method();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfVisibleForTestingMember_method_OK() async {
+ await super.test_invalidUseOfVisibleForTestingMember_method_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfVisibleForTestingMember_OK_export() async {
+ await super.test_invalidUseOfVisibleForTestingMember_OK_export();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfVisibleForTestingMember_propertyAccess() async {
+ await super.test_invalidUseOfVisibleForTestingMember_propertyAccess();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseOfVisibleForTestingMember_topLevelFunction() async {
+ await super.test_invalidUseOfVisibleForTestingMember_topLevelFunction();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseProtectedAndForTesting_asProtected_OK() async {
+ await super.test_invalidUseProtectedAndForTesting_asProtected_OK();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUseProtectedAndForTesting_asTesting_OK() async {
+ await super.test_invalidUseProtectedAndForTesting_asTesting_OK();
+ }
+
+ @override
+ @failingTest
test_isNotDouble() {
// Bad state: No data for is at 10
return super.test_isNotDouble();
@@ -235,6 +641,34 @@
return super.test_missingJsLibAnnotation_variable();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_mustBeImmutable_direct() async {
+ await super.test_mustBeImmutable_direct();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_mustBeImmutable_extends() async {
+ await super.test_mustBeImmutable_extends();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_mustBeImmutable_fromMixin() async {
+ await super.test_mustBeImmutable_fromMixin();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_mustBeImmutable_instance() async {
+ await super.test_mustBeImmutable_instance();
+ }
+
@failingTest
@override
test_mustCallSuper() async {
@@ -242,6 +676,13 @@
return super.test_mustCallSuper();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_mustCallSuper_fromInterface() async {
+ await super.test_mustCallSuper_fromInterface();
+ }
+
@failingTest
@override
test_mustCallSuper_indirect() async {
@@ -249,6 +690,27 @@
return super.test_mustCallSuper_indirect();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_mustCallSuper_overridden() async {
+ await super.test_mustCallSuper_overridden();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_mustCallSuper_overridden_w_future() async {
+ await super.test_mustCallSuper_overridden_w_future();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_mustCallSuper_overridden_w_future2() async {
+ await super.test_mustCallSuper_overridden_w_future2();
+ }
+
@failingTest
@override
test_nullAwareBeforeOperator_ok_is_not() {
@@ -258,6 +720,34 @@
@override
@failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_overrideOnNonOverridingField_invalid() async {
+ await super.test_overrideOnNonOverridingField_invalid();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_overrideOnNonOverridingGetter_invalid() async {
+ await super.test_overrideOnNonOverridingGetter_invalid();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_overrideOnNonOverridingMethod_invalid() async {
+ await super.test_overrideOnNonOverridingMethod_invalid();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_overrideOnNonOverridingSetter_invalid() async {
+ await super.test_overrideOnNonOverridingSetter_invalid();
+ }
+
+ @override
+ @failingTest
test_required_constructor_param() async {
return super.test_required_constructor_param();
}
diff --git a/pkg/analyzer/test/generated/non_error_resolver_kernel_test.dart b/pkg/analyzer/test/generated/non_error_resolver_kernel_test.dart
index 2f7a8c9..b080ee6 100644
--- a/pkg/analyzer/test/generated/non_error_resolver_kernel_test.dart
+++ b/pkg/analyzer/test/generated/non_error_resolver_kernel_test.dart
@@ -283,6 +283,13 @@
@override
@failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_instance_creation_inside_annotation() async {
+ return super.test_instance_creation_inside_annotation();
+ }
+
+ @override
+ @failingTest
@potentialAnalyzerProblem
test_integerLiteralOutOfRange_negative_valid() async {
return super.test_integerLiteralOutOfRange_negative_valid();
@@ -306,6 +313,13 @@
@override
@failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidAnnotation_constantVariable_topLevel() async {
+ return super.test_invalidAnnotation_constantVariable_topLevel();
+ }
+
+ @override
+ @failingTest
test_invalidAnnotation_constantVariable_topLevel_importWithPrefix() {
// type 'PrefixedIdentifierImpl' is not a subtype of type 'SimpleIdentifier'
// of 'topEntity'
@@ -430,13 +444,6 @@
@override
@failingTest
- @potentialAnalyzerProblem
- test_typeArgument_boundToFunctionType() async {
- return super.test_typeArgument_boundToFunctionType();
- }
-
- @override
- @failingTest
test_undefinedGetter_static_conditionalAccess() {
// Bad state: No data for A at 36
return super.test_undefinedGetter_static_conditionalAccess();
diff --git a/pkg/analyzer/test/generated/non_error_resolver_test.dart b/pkg/analyzer/test/generated/non_error_resolver_test.dart
index 1084149..6a12526 100644
--- a/pkg/analyzer/test/generated/non_error_resolver_test.dart
+++ b/pkg/analyzer/test/generated/non_error_resolver_test.dart
@@ -5386,7 +5386,7 @@
}
test_typeArgument_boundToFunctionType() async {
- Source source = addSource("class A<T extends void Function<T>(T)>{}");
+ Source source = addSource("class A<T extends void Function(T)>{}");
await computeAnalysisResult(source);
assertNoErrors(source);
verify([source]);
diff --git a/pkg/analyzer/test/generated/non_hint_code_kernel_test.dart b/pkg/analyzer/test/generated/non_hint_code_kernel_test.dart
index dc39f65..b3fe456 100644
--- a/pkg/analyzer/test/generated/non_hint_code_kernel_test.dart
+++ b/pkg/analyzer/test/generated/non_hint_code_kernel_test.dart
@@ -48,11 +48,10 @@
@override
@failingTest
- test_deprecatedAnnotationUse_namedParameter_inNestedLocalFunction() {
- // Failed assertion: line 215 pos 14: 'node.parent is PartOfDirective ||
- // node.parent is EnumConstantDeclaration': is not true.
+ test_deprecatedAnnotationUse_namedParameter_inDefiningLocalFunction() {
+ // Failed to resolve 1 nodes
return super
- .test_deprecatedAnnotationUse_namedParameter_inNestedLocalFunction();
+ .test_deprecatedAnnotationUse_namedParameter_inDefiningLocalFunction();
}
@override
@@ -65,10 +64,25 @@
@override
@failingTest
- test_deprecatedAnnotationUse_namedParameter_inDefiningLocalFunction() {
- // Failed to resolve 1 nodes
+ test_deprecatedAnnotationUse_namedParameter_inNestedLocalFunction() {
+ // Failed assertion: line 215 pos 14: 'node.parent is PartOfDirective ||
+ // node.parent is EnumConstantDeclaration': is not true.
return super
- .test_deprecatedAnnotationUse_namedParameter_inDefiningLocalFunction();
+ .test_deprecatedAnnotationUse_namedParameter_inNestedLocalFunction();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedMemberUse_inDeprecatedClass() async {
+ await super.test_deprecatedMemberUse_inDeprecatedClass();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedMemberUse_inDeprecatedFunction() async {
+ await super.test_deprecatedMemberUse_inDeprecatedFunction();
}
@failingTest
@@ -82,6 +96,113 @@
@override
@failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedMemberUse_inDeprecatedMethod() async {
+ await super.test_deprecatedMemberUse_inDeprecatedMethod();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_deprecatedMemberUse_inDeprecatedMethod_inDeprecatedClass() async {
+ await super.test_deprecatedMemberUse_inDeprecatedMethod_inDeprecatedClass();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_missingReturn_alwaysThrows() async {
+ await super.test_missingReturn_alwaysThrows();
+ }
+
+ @override
+ @failingTest
+ test_overrideOnNonOverridingField_inInterface() {
+ // Expected 1 errors of type
+ // StrongModeCode.STRONG_MODE_INVALID_METHOD_OVERRIDE, found 0
+ return super.test_overrideOnNonOverridingField_inInterface();
+ }
+
+ @override
+ @failingTest
+ test_overrideOnNonOverridingField_inSuperclass() {
+ // Expected 1 errors of type
+ // StrongModeCode.STRONG_MODE_INVALID_METHOD_OVERRIDE, found 0
+ return super.test_overrideOnNonOverridingField_inSuperclass();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_overrideOnNonOverridingGetter_inInterface() async {
+ await super.test_overrideOnNonOverridingGetter_inInterface();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_overrideOnNonOverridingGetter_inSuperclass() async {
+ await super.test_overrideOnNonOverridingGetter_inSuperclass();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_overrideOnNonOverridingMethod_inInterface() async {
+ await super.test_overrideOnNonOverridingMethod_inInterface();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_overrideOnNonOverridingMethod_inSuperclass() async {
+ await super.test_overrideOnNonOverridingMethod_inSuperclass();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_overrideOnNonOverridingMethod_inSuperclass_abstract() async {
+ await super.test_overrideOnNonOverridingMethod_inSuperclass_abstract();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_overrideOnNonOverridingSetter_inInterface() async {
+ await super.test_overrideOnNonOverridingSetter_inInterface();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_overrideOnNonOverridingSetter_inSuperclass() async {
+ await super.test_overrideOnNonOverridingSetter_inSuperclass();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_proxy_annotation_prefixed() async {
+ await super.test_proxy_annotation_prefixed();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_proxy_annotation_prefixed2() async {
+ await super.test_proxy_annotation_prefixed2();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_proxy_annotation_prefixed3() async {
+ await super.test_proxy_annotation_prefixed3();
+ }
+
+ @override
+ @failingTest
@notForDart2
test_undefinedOperator_binaryExpression_inSubtype() async {
await super.test_undefinedOperator_binaryExpression_inSubtype();
@@ -133,22 +254,6 @@
// await super.test_unusedImport_annotationOnDirective();
}
- @override
- @failingTest
- test_overrideOnNonOverridingField_inSuperclass() {
- // Expected 1 errors of type
- // StrongModeCode.STRONG_MODE_INVALID_METHOD_OVERRIDE, found 0
- return super.test_overrideOnNonOverridingField_inSuperclass();
- }
-
- @override
- @failingTest
- test_overrideOnNonOverridingField_inInterface() {
- // Expected 1 errors of type
- // StrongModeCode.STRONG_MODE_INVALID_METHOD_OVERRIDE, found 0
- return super.test_overrideOnNonOverridingField_inInterface();
- }
-
@failingTest
@override
@potentialAnalyzerProblem
diff --git a/pkg/analyzer/test/generated/parser_fasta_listener.dart b/pkg/analyzer/test/generated/parser_fasta_listener.dart
index a341ce7..9697a3c 100644
--- a/pkg/analyzer/test/generated/parser_fasta_listener.dart
+++ b/pkg/analyzer/test/generated/parser_fasta_listener.dart
@@ -508,8 +508,8 @@
}
@override
- void beginTypeVariable(Token name) {
- super.beginTypeVariable(name);
+ void beginTypeVariable(Token token) {
+ super.beginTypeVariable(token);
begin('TypeVariable');
}
@@ -1037,15 +1037,15 @@
}
@override
- void endTypeVariable(Token token, Token extendsOrSuper) {
+ void endTypeVariable(Token token, int index, Token extendsOrSuper) {
end('TypeVariable');
- super.endTypeVariable(token, extendsOrSuper);
+ super.endTypeVariable(token, index, extendsOrSuper);
}
@override
- void endTypeVariables(int count, Token beginToken, Token endToken) {
+ void endTypeVariables(Token beginToken, Token endToken) {
end('TypeVariables');
- super.endTypeVariables(count, beginToken, endToken);
+ super.endTypeVariables(beginToken, endToken);
}
@override
@@ -1169,4 +1169,9 @@
expectIn('CompilationUnit');
listener.handleScript(token);
}
+
+ @override
+ void handleTypeVariablesDefined(Token token, int count) {
+ listener.handleTypeVariablesDefined(token, count);
+ }
}
diff --git a/pkg/analyzer/test/generated/parser_forest_test.dart b/pkg/analyzer/test/generated/parser_forest_test.dart
deleted file mode 100644
index 7ca4c06..0000000
--- a/pkg/analyzer/test/generated/parser_forest_test.dart
+++ /dev/null
@@ -1,6141 +0,0 @@
-// Copyright (c) 2018, 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.
-
-import 'package:test/test.dart';
-import 'package:test_reflective_loader/test_reflective_loader.dart';
-
-import '../src/fasta/body_builder_test_helper.dart';
-import 'parser_test.dart';
-
-main() {
- return CompilerTestContext.runWithTestOptions((_) {
- defineReflectiveSuite(() {
- defineReflectiveTests(ClassMemberParserTest_Forest);
- defineReflectiveTests(ComplexParserTest_Forest);
- defineReflectiveTests(ErrorParserTest_Forest);
- defineReflectiveTests(ExpressionParserTest_Forest);
- defineReflectiveTests(FormalParameterParserTest_Forest);
- defineReflectiveTests(RecoveryParserTest_Forest);
- defineReflectiveTests(SimpleParserTest_Forest);
- defineReflectiveTests(StatementParserTest_Forest);
- defineReflectiveTests(TopLevelParserTest_Forest);
- });
- });
-}
-
-void dart2Failure() {
- fail(
- 'This passes under Dart 1, but fails under Dart 2 because of a cast exception');
-}
-
-@reflectiveTest
-class ClassMemberParserTest_Forest extends FastaBodyBuilderTestCase
- with ClassMemberParserTestMixin {
- ClassMemberParserTest_Forest() : super(false);
-
- @failingTest
- void test_parseAwaitExpression_asStatement_inAsync() {
- super.test_parseAwaitExpression_asStatement_inAsync();
- }
-
- @failingTest
- void test_parseAwaitExpression_asStatement_inSync() {
- super.test_parseAwaitExpression_asStatement_inSync();
- }
-
- @failingTest
- void test_parseAwaitExpression_inSync() {
- super.test_parseAwaitExpression_inSync();
- }
-
- @failingTest
- void test_parseClassMember_constructor_withDocComment() {
- super.test_parseClassMember_constructor_withDocComment();
- }
-
- @failingTest
- void test_parseClassMember_constructor_withInitializers() {
- super.test_parseClassMember_constructor_withInitializers();
- }
-
- @failingTest
- void test_parseClassMember_field_covariant() {
- super.test_parseClassMember_field_covariant();
- }
-
- @failingTest
- void test_parseClassMember_field_generic() {
- super.test_parseClassMember_field_generic();
- }
-
- @failingTest
- void test_parseClassMember_field_gftType_gftReturnType() {
- super.test_parseClassMember_field_gftType_gftReturnType();
- }
-
- @failingTest
- void test_parseClassMember_field_gftType_noReturnType() {
- super.test_parseClassMember_field_gftType_noReturnType();
- }
-
- @failingTest
- void test_parseClassMember_field_instance_prefixedType() {
- super.test_parseClassMember_field_instance_prefixedType();
- }
-
- @failingTest
- void test_parseClassMember_field_namedGet() {
- super.test_parseClassMember_field_namedGet();
- }
-
- @failingTest
- void test_parseClassMember_field_namedOperator() {
- super.test_parseClassMember_field_namedOperator();
- }
-
- @failingTest
- void test_parseClassMember_field_namedOperator_withAssignment() {
- super.test_parseClassMember_field_namedOperator_withAssignment();
- }
-
- @failingTest
- void test_parseClassMember_field_namedSet() {
- super.test_parseClassMember_field_namedSet();
- }
-
- @failingTest
- void test_parseClassMember_field_nameKeyword() {
- super.test_parseClassMember_field_nameKeyword();
- }
-
- @failingTest
- void test_parseClassMember_field_nameMissing() {
- super.test_parseClassMember_field_nameMissing();
- }
-
- @failingTest
- void test_parseClassMember_field_nameMissing2() {
- super.test_parseClassMember_field_nameMissing2();
- }
-
- @failingTest
- void test_parseClassMember_field_static() {
- super.test_parseClassMember_field_static();
- }
-
- @failingTest
- void test_parseClassMember_getter_functionType() {
- super.test_parseClassMember_getter_functionType();
- }
-
- @failingTest
- void test_parseClassMember_getter_void() {
- super.test_parseClassMember_getter_void();
- }
-
- @failingTest
- void test_parseClassMember_method_external() {
- super.test_parseClassMember_method_external();
- }
-
- @failingTest
- void test_parseClassMember_method_external_withTypeAndArgs() {
- super.test_parseClassMember_method_external_withTypeAndArgs();
- }
-
- @failingTest
- void test_parseClassMember_method_generic_comment_noReturnType() {
- super.test_parseClassMember_method_generic_comment_noReturnType();
- }
-
- @failingTest
- void test_parseClassMember_method_generic_comment_parameterType() {
- super.test_parseClassMember_method_generic_comment_parameterType();
- }
-
- @failingTest
- void test_parseClassMember_method_generic_comment_returnType() {
- super.test_parseClassMember_method_generic_comment_returnType();
- }
-
- @failingTest
- void test_parseClassMember_method_generic_comment_returnType_bound() {
- super.test_parseClassMember_method_generic_comment_returnType_bound();
- }
-
- @failingTest
- void test_parseClassMember_method_generic_comment_returnType_complex() {
- super.test_parseClassMember_method_generic_comment_returnType_complex();
- }
-
- @failingTest
- void test_parseClassMember_method_generic_comment_void() {
- super.test_parseClassMember_method_generic_comment_void();
- }
-
- @failingTest
- void test_parseClassMember_method_generic_noReturnType() {
- super.test_parseClassMember_method_generic_noReturnType();
- }
-
- @failingTest
- void test_parseClassMember_method_generic_parameterType() {
- super.test_parseClassMember_method_generic_parameterType();
- }
-
- @failingTest
- void test_parseClassMember_method_generic_returnType() {
- super.test_parseClassMember_method_generic_returnType();
- }
-
- @failingTest
- void test_parseClassMember_method_generic_returnType_bound() {
- super.test_parseClassMember_method_generic_returnType_bound();
- }
-
- @failingTest
- void test_parseClassMember_method_generic_returnType_complex() {
- super.test_parseClassMember_method_generic_returnType_complex();
- }
-
- @failingTest
- void test_parseClassMember_method_generic_returnType_static() {
- super.test_parseClassMember_method_generic_returnType_static();
- }
-
- @failingTest
- void test_parseClassMember_method_generic_void() {
- super.test_parseClassMember_method_generic_void();
- }
-
- @failingTest
- void test_parseClassMember_method_get_noType() {
- super.test_parseClassMember_method_get_noType();
- }
-
- @failingTest
- void test_parseClassMember_method_get_type() {
- super.test_parseClassMember_method_get_type();
- }
-
- @failingTest
- void test_parseClassMember_method_get_void() {
- super.test_parseClassMember_method_get_void();
- }
-
- @failingTest
- void test_parseClassMember_method_gftReturnType_noReturnType() {
- super.test_parseClassMember_method_gftReturnType_noReturnType();
- }
-
- @failingTest
- void test_parseClassMember_method_gftReturnType_voidReturnType() {
- super.test_parseClassMember_method_gftReturnType_voidReturnType();
- }
-
- @failingTest
- void test_parseClassMember_method_native_allowed() {
- super.test_parseClassMember_method_native_allowed();
- }
-
- @failingTest
- void test_parseClassMember_method_native_missing_literal_allowed() {
- super.test_parseClassMember_method_native_missing_literal_allowed();
- }
-
- @failingTest
- void test_parseClassMember_method_native_missing_literal_not_allowed() {
- super.test_parseClassMember_method_native_missing_literal_not_allowed();
- }
-
- @failingTest
- void test_parseClassMember_method_native_not_allowed() {
- super.test_parseClassMember_method_native_not_allowed();
- }
-
- @failingTest
- void test_parseClassMember_method_native_with_body_allowed() {
- super.test_parseClassMember_method_native_with_body_allowed();
- }
-
- @failingTest
- void test_parseClassMember_method_native_with_body_not_allowed() {
- super.test_parseClassMember_method_native_with_body_not_allowed();
- }
-
- @failingTest
- void test_parseClassMember_method_operator_noType() {
- super.test_parseClassMember_method_operator_noType();
- }
-
- @failingTest
- void test_parseClassMember_method_operator_type() {
- super.test_parseClassMember_method_operator_type();
- }
-
- @failingTest
- void test_parseClassMember_method_operator_void() {
- super.test_parseClassMember_method_operator_void();
- }
-
- @failingTest
- void test_parseClassMember_method_returnType_functionType() {
- super.test_parseClassMember_method_returnType_functionType();
- }
-
- @failingTest
- void test_parseClassMember_method_returnType_parameterized() {
- super.test_parseClassMember_method_returnType_parameterized();
- }
-
- @failingTest
- void test_parseClassMember_method_set_noType() {
- super.test_parseClassMember_method_set_noType();
- }
-
- @failingTest
- void test_parseClassMember_method_set_type() {
- super.test_parseClassMember_method_set_type();
- }
-
- @failingTest
- void test_parseClassMember_method_set_void() {
- super.test_parseClassMember_method_set_void();
- }
-
- @failingTest
- void test_parseClassMember_method_static_generic_comment_returnType() {
- super.test_parseClassMember_method_static_generic_comment_returnType();
- }
-
- @failingTest
- void test_parseClassMember_method_trailing_commas() {
- super.test_parseClassMember_method_trailing_commas();
- }
-
- @failingTest
- void test_parseClassMember_operator_functionType() {
- super.test_parseClassMember_operator_functionType();
- }
-
- @failingTest
- void test_parseClassMember_operator_index() {
- super.test_parseClassMember_operator_index();
- }
-
- @failingTest
- void test_parseClassMember_operator_indexAssign() {
- super.test_parseClassMember_operator_indexAssign();
- }
-
- @failingTest
- void test_parseClassMember_operator_lessThan() {
- super.test_parseClassMember_operator_lessThan();
- }
-
- @failingTest
- void test_parseClassMember_redirectingFactory_const() {
- super.test_parseClassMember_redirectingFactory_const();
- }
-
- @failingTest
- void test_parseClassMember_redirectingFactory_expressionBody() {
- super.test_parseClassMember_redirectingFactory_expressionBody();
- }
-
- @failingTest
- void test_parseClassMember_redirectingFactory_nonConst() {
- super.test_parseClassMember_redirectingFactory_nonConst();
- }
-
- @failingTest
- void test_parseConstructor_assert() {
- super.test_parseConstructor_assert();
- }
-
- @failingTest
- void test_parseConstructor_factory_const_external() {
- super.test_parseConstructor_factory_const_external();
- }
-
- @failingTest
- void test_parseConstructor_factory_named() {
- super.test_parseConstructor_factory_named();
- }
-
- @failingTest
- void test_parseConstructor_initializers_field() {
- super.test_parseConstructor_initializers_field();
- }
-
- @failingTest
- void test_parseConstructor_named() {
- super.test_parseConstructor_named();
- }
-
- @failingTest
- void test_parseConstructor_unnamed() {
- super.test_parseConstructor_unnamed();
- }
-
- @failingTest
- void test_parseConstructor_with_pseudo_function_literal() {
- super.test_parseConstructor_with_pseudo_function_literal();
- }
-
- @failingTest
- void test_parseConstructorFieldInitializer_qualified() {
- super.test_parseConstructorFieldInitializer_qualified();
- }
-
- @failingTest
- void test_parseConstructorFieldInitializer_unqualified() {
- super.test_parseConstructorFieldInitializer_unqualified();
- }
-
- @failingTest
- void test_parseGetter_nonStatic() {
- super.test_parseGetter_nonStatic();
- }
-
- @failingTest
- void test_parseGetter_static() {
- super.test_parseGetter_static();
- }
-
- @failingTest
- void test_parseInitializedIdentifierList_type() {
- super.test_parseInitializedIdentifierList_type();
- }
-
- @failingTest
- void test_parseInitializedIdentifierList_var() {
- super.test_parseInitializedIdentifierList_var();
- }
-
- @failingTest
- void test_parseOperator() {
- super.test_parseOperator();
- }
-
- @failingTest
- void test_parseSetter_nonStatic() {
- super.test_parseSetter_nonStatic();
- }
-
- @failingTest
- void test_parseSetter_static() {
- super.test_parseSetter_static();
- }
-
- @failingTest
- void test_simpleFormalParameter_withDocComment() {
- super.test_simpleFormalParameter_withDocComment();
- }
-}
-
-@reflectiveTest
-class ComplexParserTest_Forest extends FastaBodyBuilderTestCase
- with ComplexParserTestMixin {
- ComplexParserTest_Forest() : super(false);
-
- @failingTest
- void test_additiveExpression_normal() {
- super.test_additiveExpression_normal();
- }
-
- @failingTest
- void test_additiveExpression_noSpaces() {
- super.test_additiveExpression_noSpaces();
- }
-
- @failingTest
- void test_additiveExpression_precedence_multiplicative_left() {
- super.test_additiveExpression_precedence_multiplicative_left();
- }
-
- @failingTest
- void test_additiveExpression_precedence_multiplicative_left_withSuper() {
- super.test_additiveExpression_precedence_multiplicative_left_withSuper();
- }
-
- @failingTest
- void test_additiveExpression_precedence_multiplicative_right() {
- super.test_additiveExpression_precedence_multiplicative_right();
- }
-
- @failingTest
- void test_additiveExpression_super() {
- super.test_additiveExpression_super();
- }
-
- @failingTest
- void test_assignableExpression_arguments_normal_chain() {
- super.test_assignableExpression_arguments_normal_chain();
- }
-
- @failingTest
- void test_assignableExpression_arguments_normal_chain_typeArgumentComments() {
- super
- .test_assignableExpression_arguments_normal_chain_typeArgumentComments();
- }
-
- @failingTest
- void test_assignableExpression_arguments_normal_chain_typeArguments() {
- super.test_assignableExpression_arguments_normal_chain_typeArguments();
- }
-
- @failingTest
- void test_assignmentExpression_compound() {
- super.test_assignmentExpression_compound();
- dart2Failure();
- }
-
- @failingTest
- void test_assignmentExpression_indexExpression() {
- super.test_assignmentExpression_indexExpression();
- dart2Failure();
- }
-
- @failingTest
- void test_assignmentExpression_prefixedIdentifier() {
- super.test_assignmentExpression_prefixedIdentifier();
- }
-
- @failingTest
- void test_assignmentExpression_propertyAccess() {
- super.test_assignmentExpression_propertyAccess();
- }
-
- @failingTest
- void test_bitwiseAndExpression_normal() {
- super.test_bitwiseAndExpression_normal();
- }
-
- @failingTest
- void test_bitwiseAndExpression_precedence_equality_left() {
- super.test_bitwiseAndExpression_precedence_equality_left();
- }
-
- @failingTest
- void test_bitwiseAndExpression_precedence_equality_right() {
- super.test_bitwiseAndExpression_precedence_equality_right();
- }
-
- @failingTest
- void test_bitwiseAndExpression_super() {
- super.test_bitwiseAndExpression_super();
- }
-
- @failingTest
- void test_bitwiseOrExpression_normal() {
- super.test_bitwiseOrExpression_normal();
- }
-
- @failingTest
- void test_bitwiseOrExpression_precedence_xor_left() {
- super.test_bitwiseOrExpression_precedence_xor_left();
- }
-
- @failingTest
- void test_bitwiseOrExpression_precedence_xor_right() {
- super.test_bitwiseOrExpression_precedence_xor_right();
- }
-
- @failingTest
- void test_bitwiseOrExpression_super() {
- super.test_bitwiseOrExpression_super();
- }
-
- @failingTest
- void test_bitwiseXorExpression_normal() {
- super.test_bitwiseXorExpression_normal();
- }
-
- @failingTest
- void test_bitwiseXorExpression_precedence_and_left() {
- super.test_bitwiseXorExpression_precedence_and_left();
- }
-
- @failingTest
- void test_bitwiseXorExpression_precedence_and_right() {
- super.test_bitwiseXorExpression_precedence_and_right();
- }
-
- @failingTest
- void test_bitwiseXorExpression_super() {
- super.test_bitwiseXorExpression_super();
- }
-
- @failingTest
- void test_cascade_withAssignment() {
- super.test_cascade_withAssignment();
- }
-
- @failingTest
- void test_conditionalExpression_precedence_ifNullExpression() {
- super.test_conditionalExpression_precedence_ifNullExpression();
- }
-
- @failingTest
- void test_conditionalExpression_precedence_logicalOrExpression() {
- super.test_conditionalExpression_precedence_logicalOrExpression();
- }
-
- @failingTest
- void test_conditionalExpression_precedence_nullableType_as() {
- super.test_conditionalExpression_precedence_nullableType_as();
- }
-
- @failingTest
- void test_conditionalExpression_precedence_nullableType_is() {
- super.test_conditionalExpression_precedence_nullableType_is();
- }
-
- @failingTest
- void test_constructor_initializer_withParenthesizedExpression() {
- super.test_constructor_initializer_withParenthesizedExpression();
- }
-
- @failingTest
- void test_equalityExpression_normal() {
- super.test_equalityExpression_normal();
- }
-
- @failingTest
- void test_equalityExpression_precedence_relational_left() {
- super.test_equalityExpression_precedence_relational_left();
- }
-
- @failingTest
- void test_equalityExpression_precedence_relational_right() {
- super.test_equalityExpression_precedence_relational_right();
- }
-
- @failingTest
- void test_equalityExpression_super() {
- super.test_equalityExpression_super();
- }
-
- @failingTest
- void test_ifNullExpression() {
- super.test_ifNullExpression();
- }
-
- @failingTest
- void test_ifNullExpression_precedence_logicalOr_left() {
- super.test_ifNullExpression_precedence_logicalOr_left();
- }
-
- @failingTest
- void test_ifNullExpression_precedence_logicalOr_right() {
- super.test_ifNullExpression_precedence_logicalOr_right();
- }
-
- @failingTest
- void test_logicalAndExpression() {
- super.test_logicalAndExpression();
- dart2Failure();
- }
-
- @failingTest
- void test_logicalAndExpression_precedence_bitwiseOr_left() {
- super.test_logicalAndExpression_precedence_bitwiseOr_left();
- }
-
- @failingTest
- void test_logicalAndExpression_precedence_bitwiseOr_right() {
- super.test_logicalAndExpression_precedence_bitwiseOr_right();
- }
-
- @failingTest
- void test_logicalAndExpressionStatement() {
- super.test_logicalAndExpressionStatement();
- }
-
- @failingTest
- void test_logicalOrExpression() {
- super.test_logicalOrExpression();
- dart2Failure();
- }
-
- @failingTest
- void test_logicalOrExpression_precedence_logicalAnd_left() {
- super.test_logicalOrExpression_precedence_logicalAnd_left();
- dart2Failure();
- }
-
- @failingTest
- void test_logicalOrExpression_precedence_logicalAnd_right() {
- super.test_logicalOrExpression_precedence_logicalAnd_right();
- dart2Failure();
- }
-
- @failingTest
- void test_methodInvocation1() {
- super.test_methodInvocation1();
- }
-
- @failingTest
- void test_methodInvocation2() {
- super.test_methodInvocation2();
- }
-
- @failingTest
- void test_methodInvocation3() {
- super.test_methodInvocation3();
- }
-
- @failingTest
- void test_multiplicativeExpression_normal() {
- super.test_multiplicativeExpression_normal();
- }
-
- @failingTest
- void test_multiplicativeExpression_precedence_unary_left() {
- super.test_multiplicativeExpression_precedence_unary_left();
- }
-
- @failingTest
- void test_multiplicativeExpression_precedence_unary_right() {
- super.test_multiplicativeExpression_precedence_unary_right();
- }
-
- @failingTest
- void test_multiplicativeExpression_super() {
- super.test_multiplicativeExpression_super();
- }
-
- @failingTest
- void test_relationalExpression_precedence_shift_right() {
- super.test_relationalExpression_precedence_shift_right();
- }
-
- @failingTest
- void test_shiftExpression_normal() {
- super.test_shiftExpression_normal();
- }
-
- @failingTest
- void test_shiftExpression_precedence_additive_left() {
- super.test_shiftExpression_precedence_additive_left();
- }
-
- @failingTest
- void test_shiftExpression_precedence_additive_right() {
- super.test_shiftExpression_precedence_additive_right();
- }
-
- @failingTest
- void test_shiftExpression_super() {
- super.test_shiftExpression_super();
- }
-
- @failingTest
- void test_topLevelFunction_nestedGenericFunction() {
- super.test_topLevelFunction_nestedGenericFunction();
- }
-}
-
-@reflectiveTest
-class ErrorParserTest_Forest extends FastaBodyBuilderTestCase
- with ErrorParserTestMixin {
- ErrorParserTest_Forest() : super(false);
-
- @failingTest
- void test_abstractClassMember_constructor() {
- super.test_abstractClassMember_constructor();
- }
-
- @failingTest
- void test_abstractClassMember_field() {
- super.test_abstractClassMember_field();
- }
-
- @failingTest
- void test_abstractClassMember_getter() {
- super.test_abstractClassMember_getter();
- }
-
- @failingTest
- void test_abstractClassMember_method() {
- super.test_abstractClassMember_method();
- }
-
- @failingTest
- void test_abstractClassMember_setter() {
- super.test_abstractClassMember_setter();
- }
-
- @failingTest
- void test_abstractEnum() {
- super.test_abstractEnum();
- }
-
- @failingTest
- void test_abstractTopLevelFunction_function() {
- super.test_abstractTopLevelFunction_function();
- }
-
- @failingTest
- void test_abstractTopLevelFunction_getter() {
- super.test_abstractTopLevelFunction_getter();
- }
-
- @failingTest
- void test_abstractTopLevelFunction_setter() {
- super.test_abstractTopLevelFunction_setter();
- }
-
- @failingTest
- void test_abstractTopLevelVariable() {
- super.test_abstractTopLevelVariable();
- }
-
- @failingTest
- void test_abstractTypeDef() {
- super.test_abstractTypeDef();
- }
-
- @failingTest
- void test_breakOutsideOfLoop_breakInForStatement() {
- super.test_breakOutsideOfLoop_breakInForStatement();
- }
-
- @failingTest
- void test_breakOutsideOfLoop_breakInIfStatement() {
- super.test_breakOutsideOfLoop_breakInIfStatement();
- }
-
- @failingTest
- void test_breakOutsideOfLoop_breakInSwitchStatement() {
- super.test_breakOutsideOfLoop_breakInSwitchStatement();
- }
-
- @failingTest
- void test_breakOutsideOfLoop_functionExpression_inALoop() {
- super.test_breakOutsideOfLoop_functionExpression_inALoop();
- }
-
- @failingTest
- void test_breakOutsideOfLoop_functionExpression_withALoop() {
- super.test_breakOutsideOfLoop_functionExpression_withALoop();
- }
-
- @failingTest
- void test_classInClass_abstract() {
- super.test_classInClass_abstract();
- }
-
- @failingTest
- void test_classInClass_nonAbstract() {
- super.test_classInClass_nonAbstract();
- }
-
- @failingTest
- void test_classTypeAlias_abstractAfterEq() {
- super.test_classTypeAlias_abstractAfterEq();
- }
-
- @failingTest
- void test_colonInPlaceOfIn() {
- super.test_colonInPlaceOfIn();
- }
-
- @failingTest
- void test_constAndCovariant() {
- super.test_constAndCovariant();
- }
-
- @failingTest
- void test_constAndFinal() {
- super.test_constAndFinal();
- }
-
- @failingTest
- void test_constAndVar() {
- super.test_constAndVar();
- }
-
- @failingTest
- void test_constClass() {
- super.test_constClass();
- }
-
- @failingTest
- void test_constConstructorWithBody() {
- super.test_constConstructorWithBody();
- }
-
- @failingTest
- void test_constEnum() {
- super.test_constEnum();
- }
-
- @failingTest
- void test_constFactory() {
- super.test_constFactory();
- }
-
- @failingTest
- void test_constMethod() {
- super.test_constMethod();
- }
-
- @failingTest
- void test_constructorPartial() {
- super.test_constructorPartial();
- }
-
- @failingTest
- void test_constructorPartial2() {
- super.test_constructorPartial();
- }
-
- @failingTest
- void test_constructorPartial3() {
- super.test_constructorPartial();
- }
-
- @failingTest
- void test_constructorWithReturnType() {
- super.test_constructorWithReturnType();
- }
-
- @failingTest
- void test_constructorWithReturnType_var() {
- super.test_constructorWithReturnType_var();
- }
-
- @failingTest
- void test_constTypedef() {
- super.test_constTypedef();
- }
-
- @failingTest
- void test_continueOutsideOfLoop_continueInForStatement() {
- super.test_continueOutsideOfLoop_continueInForStatement();
- }
-
- @failingTest
- void test_continueOutsideOfLoop_continueInIfStatement() {
- super.test_continueOutsideOfLoop_continueInIfStatement();
- }
-
- @failingTest
- void test_continueOutsideOfLoop_continueInSwitchStatement() {
- super.test_continueOutsideOfLoop_continueInSwitchStatement();
- }
-
- @failingTest
- void test_continueOutsideOfLoop_functionExpression_inALoop() {
- super.test_continueOutsideOfLoop_functionExpression_inALoop();
- }
-
- @failingTest
- void test_continueOutsideOfLoop_functionExpression_withALoop() {
- super.test_continueOutsideOfLoop_functionExpression_withALoop();
- }
-
- @failingTest
- void test_continueWithoutLabelInCase_error() {
- super.test_continueWithoutLabelInCase_error();
- }
-
- @failingTest
- void test_continueWithoutLabelInCase_noError() {
- super.test_continueWithoutLabelInCase_noError();
- }
-
- @failingTest
- void test_continueWithoutLabelInCase_noError_switchInLoop() {
- super.test_continueWithoutLabelInCase_noError_switchInLoop();
- }
-
- @failingTest
- void test_covariantAfterVar() {
- super.test_covariantAfterVar();
- }
-
- @failingTest
- void test_covariantAndFinal() {
- super.test_covariantAndFinal();
- }
-
- @failingTest
- void test_covariantAndStatic() {
- super.test_covariantAndStatic();
- }
-
- @failingTest
- void test_covariantAndType_local() {
- super.test_covariantAndType_local();
- }
-
- @failingTest
- void test_covariantConstructor() {
- super.test_covariantConstructor();
- }
-
- @failingTest
- void test_covariantMember_getter_noReturnType() {
- super.test_covariantMember_getter_noReturnType();
- }
-
- @failingTest
- void test_covariantMember_getter_returnType() {
- super.test_covariantMember_getter_returnType();
- }
-
- @failingTest
- void test_covariantMember_method() {
- super.test_covariantMember_method();
- }
-
- @failingTest
- void test_covariantTopLevelDeclaration_class() {
- super.test_covariantTopLevelDeclaration_class();
- }
-
- @failingTest
- void test_covariantTopLevelDeclaration_enum() {
- super.test_covariantTopLevelDeclaration_enum();
- }
-
- @failingTest
- void test_covariantTopLevelDeclaration_typedef() {
- super.test_covariantTopLevelDeclaration_typedef();
- }
-
- @failingTest
- void test_defaultValueInFunctionType_named_colon() {
- super.test_defaultValueInFunctionType_named_colon();
- }
-
- @failingTest
- void test_defaultValueInFunctionType_named_equal() {
- super.test_defaultValueInFunctionType_named_equal();
- }
-
- @failingTest
- void test_defaultValueInFunctionType_positional() {
- super.test_defaultValueInFunctionType_positional();
- }
-
- @failingTest
- void test_directiveAfterDeclaration_classBeforeDirective() {
- super.test_directiveAfterDeclaration_classBeforeDirective();
- }
-
- @failingTest
- void test_directiveAfterDeclaration_classBetweenDirectives() {
- super.test_directiveAfterDeclaration_classBetweenDirectives();
- }
-
- @failingTest
- void test_duplicatedModifier_const() {
- super.test_duplicatedModifier_const();
- }
-
- @failingTest
- void test_duplicatedModifier_external() {
- super.test_duplicatedModifier_external();
- }
-
- @failingTest
- void test_duplicatedModifier_factory() {
- super.test_duplicatedModifier_factory();
- }
-
- @failingTest
- void test_duplicatedModifier_final() {
- super.test_duplicatedModifier_final();
- }
-
- @failingTest
- void test_duplicatedModifier_static() {
- super.test_duplicatedModifier_static();
- }
-
- @failingTest
- void test_duplicatedModifier_var() {
- super.test_duplicatedModifier_var();
- }
-
- @failingTest
- void test_duplicateLabelInSwitchStatement() {
- super.test_duplicateLabelInSwitchStatement();
- }
-
- @failingTest
- void test_emptyEnumBody() {
- super.test_emptyEnumBody();
- }
-
- @failingTest
- void test_enumInClass() {
- super.test_enumInClass();
- }
-
- @failingTest
- void test_equalityCannotBeEqualityOperand_eq_eq() {
- super.test_equalityCannotBeEqualityOperand_eq_eq();
- }
-
- @failingTest
- void test_equalityCannotBeEqualityOperand_eq_neq() {
- super.test_equalityCannotBeEqualityOperand_eq_neq();
- }
-
- @failingTest
- void test_equalityCannotBeEqualityOperand_neq_eq() {
- super.test_equalityCannotBeEqualityOperand_neq_eq();
- }
-
- @failingTest
- void test_expectedCaseOrDefault() {
- super.test_expectedCaseOrDefault();
- }
-
- @failingTest
- void test_expectedClassMember_inClass_afterType() {
- super.test_expectedClassMember_inClass_afterType();
- }
-
- @failingTest
- void test_expectedClassMember_inClass_beforeType() {
- super.test_expectedClassMember_inClass_beforeType();
- }
-
- @failingTest
- void test_expectedExecutable_afterAnnotation_atEOF() {
- super.test_expectedExecutable_afterAnnotation_atEOF();
- }
-
- @failingTest
- void test_expectedExecutable_inClass_afterVoid() {
- super.test_expectedExecutable_inClass_afterVoid();
- }
-
- @failingTest
- void test_expectedExecutable_topLevel_afterType() {
- super.test_expectedExecutable_topLevel_afterType();
- }
-
- @failingTest
- void test_expectedExecutable_topLevel_afterVoid() {
- super.test_expectedExecutable_topLevel_afterVoid();
- }
-
- @failingTest
- void test_expectedExecutable_topLevel_beforeType() {
- super.test_expectedExecutable_topLevel_beforeType();
- }
-
- @failingTest
- void test_expectedExecutable_topLevel_eof() {
- super.test_expectedExecutable_topLevel_eof();
- }
-
- @failingTest
- void test_expectedInterpolationIdentifier() {
- super.test_expectedInterpolationIdentifier();
- }
-
- @failingTest
- void test_expectedInterpolationIdentifier_emptyString() {
- super.test_expectedInterpolationIdentifier_emptyString();
- }
-
- @failingTest
- void test_expectedListOrMapLiteral() {
- super.test_expectedListOrMapLiteral();
- }
-
- @failingTest
- void test_expectedStringLiteral() {
- super.test_expectedStringLiteral();
- }
-
- @failingTest
- void test_expectedToken_commaMissingInArgumentList() {
- super.test_expectedToken_commaMissingInArgumentList();
- }
-
- @failingTest
- void test_expectedToken_parseStatement_afterVoid() {
- super.test_expectedToken_parseStatement_afterVoid();
- }
-
- @failingTest
- void test_expectedToken_semicolonMissingAfterExport() {
- super.test_expectedToken_semicolonMissingAfterExport();
- }
-
- @failingTest
- void test_expectedToken_semicolonMissingAfterExpression() {
- super.test_expectedToken_semicolonMissingAfterExpression();
- }
-
- @failingTest
- void test_expectedToken_semicolonMissingAfterImport() {
- super.test_expectedToken_semicolonMissingAfterImport();
- }
-
- @failingTest
- void test_expectedToken_uriAndSemicolonMissingAfterExport() {
- super.test_expectedToken_uriAndSemicolonMissingAfterExport();
- }
-
- @failingTest
- void test_expectedToken_whileMissingInDoStatement() {
- super.test_expectedToken_whileMissingInDoStatement();
- }
-
- @failingTest
- void test_expectedTypeName_as() {
- super.test_expectedTypeName_as();
- }
-
- @failingTest
- void test_expectedTypeName_as_void() {
- super.test_expectedTypeName_as_void();
- }
-
- @failingTest
- void test_expectedTypeName_is() {
- super.test_expectedTypeName_is();
- }
-
- @failingTest
- void test_expectedTypeName_is_void() {
- super.test_expectedTypeName_is_void();
- }
-
- @failingTest
- void test_exportAsType() {
- super.test_exportAsType();
- }
-
- @failingTest
- void test_exportAsType_inClass() {
- super.test_exportAsType_inClass();
- }
-
- @failingTest
- void test_exportDirectiveAfterPartDirective() {
- super.test_exportDirectiveAfterPartDirective();
- }
-
- @failingTest
- void test_externalAfterConst() {
- super.test_externalAfterConst();
- }
-
- @failingTest
- void test_externalAfterFactory() {
- super.test_externalAfterFactory();
- }
-
- @failingTest
- void test_externalAfterStatic() {
- super.test_externalAfterStatic();
- }
-
- @failingTest
- void test_externalClass() {
- super.test_externalClass();
- }
-
- @failingTest
- void test_externalConstructorWithBody_factory() {
- super.test_externalConstructorWithBody_factory();
- }
-
- @failingTest
- void test_externalConstructorWithBody_named() {
- super.test_externalConstructorWithBody_named();
- }
-
- @failingTest
- void test_externalEnum() {
- super.test_externalEnum();
- }
-
- @failingTest
- void test_externalField_const() {
- super.test_externalField_const();
- }
-
- @failingTest
- void test_externalField_final() {
- super.test_externalField_final();
- }
-
- @failingTest
- void test_externalField_static() {
- super.test_externalField_static();
- }
-
- @failingTest
- void test_externalField_typed() {
- super.test_externalField_typed();
- }
-
- @failingTest
- void test_externalField_untyped() {
- super.test_externalField_untyped();
- }
-
- @failingTest
- void test_externalGetterWithBody() {
- super.test_externalGetterWithBody();
- }
-
- @failingTest
- void test_externalMethodWithBody() {
- super.test_externalMethodWithBody();
- }
-
- @failingTest
- void test_externalOperatorWithBody() {
- super.test_externalOperatorWithBody();
- }
-
- @failingTest
- void test_externalSetterWithBody() {
- super.test_externalSetterWithBody();
- }
-
- @failingTest
- void test_externalTypedef() {
- super.test_externalTypedef();
- }
-
- @failingTest
- void test_extraCommaInParameterList() {
- super.test_extraCommaInParameterList();
- }
-
- @failingTest
- void test_extraCommaTrailingNamedParameterGroup() {
- super.test_extraCommaTrailingNamedParameterGroup();
- }
-
- @failingTest
- void test_extraCommaTrailingPositionalParameterGroup() {
- super.test_extraCommaTrailingPositionalParameterGroup();
- }
-
- @failingTest
- void test_extraTrailingCommaInParameterList() {
- super.test_extraTrailingCommaInParameterList();
- }
-
- @failingTest
- void test_factoryTopLevelDeclaration_class() {
- super.test_factoryTopLevelDeclaration_class();
- }
-
- @failingTest
- void test_factoryTopLevelDeclaration_enum() {
- super.test_factoryTopLevelDeclaration_enum();
- }
-
- @failingTest
- void test_factoryTopLevelDeclaration_typedef() {
- super.test_factoryTopLevelDeclaration_typedef();
- }
-
- @failingTest
- void test_factoryWithInitializers() {
- super.test_factoryWithInitializers();
- }
-
- @failingTest
- void test_factoryWithoutBody() {
- super.test_factoryWithoutBody();
- }
-
- @failingTest
- void test_fieldInitializerOutsideConstructor() {
- super.test_fieldInitializerOutsideConstructor();
- }
-
- @failingTest
- void test_finalAndCovariant() {
- super.test_finalAndCovariant();
- }
-
- @failingTest
- void test_finalAndVar() {
- super.test_finalAndVar();
- }
-
- @failingTest
- void test_finalClass() {
- super.test_finalClass();
- }
-
- @failingTest
- void test_finalClassMember_modifierOnly() {
- super.test_finalClassMember_modifierOnly();
- }
-
- @failingTest
- void test_finalConstructor() {
- super.test_finalConstructor();
- }
-
- @failingTest
- void test_finalEnum() {
- super.test_finalEnum();
- }
-
- @failingTest
- void test_finalMethod() {
- super.test_finalMethod();
- }
-
- @failingTest
- void test_finalTypedef() {
- super.test_finalTypedef();
- }
-
- @failingTest
- void test_functionTypedField_invalidType_abstract() {
- super.test_functionTypedField_invalidType_abstract();
- }
-
- @failingTest
- void test_functionTypedField_invalidType_class() {
- super.test_functionTypedField_invalidType_class();
- }
-
- @failingTest
- void test_functionTypedParameter_const() {
- super.test_functionTypedParameter_const();
- }
-
- @failingTest
- void test_functionTypedParameter_final() {
- super.test_functionTypedParameter_final();
- }
-
- @failingTest
- void test_functionTypedParameter_incomplete1() {
- super.test_functionTypedParameter_incomplete1();
- }
-
- @failingTest
- void test_functionTypedParameter_var() {
- super.test_functionTypedParameter_var();
- }
-
- @failingTest
- void test_genericFunctionType_asIdentifier() {
- super.test_genericFunctionType_asIdentifier();
- }
-
- @failingTest
- void test_genericFunctionType_asIdentifier2() {
- super.test_genericFunctionType_asIdentifier2();
- }
-
- @failingTest
- void test_genericFunctionType_asIdentifier3() {
- super.test_genericFunctionType_asIdentifier3();
- }
-
- @failingTest
- void test_genericFunctionType_extraLessThan() {
- super.test_genericFunctionType_extraLessThan();
- }
-
- @failingTest
- void test_getterInFunction_block_noReturnType() {
- super.test_getterInFunction_block_noReturnType();
- }
-
- @failingTest
- void test_getterInFunction_block_returnType() {
- super.test_getterInFunction_block_returnType();
- }
-
- @failingTest
- void test_getterInFunction_expression_noReturnType() {
- super.test_getterInFunction_expression_noReturnType();
- }
-
- @failingTest
- void test_getterInFunction_expression_returnType() {
- super.test_getterInFunction_expression_returnType();
- }
-
- @failingTest
- void test_getterWithParameters() {
- super.test_getterWithParameters();
- }
-
- @failingTest
- void test_illegalAssignmentToNonAssignable_assign_int() {
- super.test_illegalAssignmentToNonAssignable_assign_int();
- }
-
- @failingTest
- void test_illegalAssignmentToNonAssignable_assign_this() {
- super.test_illegalAssignmentToNonAssignable_assign_this();
- }
-
- @failingTest
- void test_illegalAssignmentToNonAssignable_postfix_minusMinus_literal() {
- super.test_illegalAssignmentToNonAssignable_postfix_minusMinus_literal();
- }
-
- @failingTest
- void test_illegalAssignmentToNonAssignable_postfix_plusPlus_literal() {
- super.test_illegalAssignmentToNonAssignable_postfix_plusPlus_literal();
- }
-
- @failingTest
- void test_illegalAssignmentToNonAssignable_postfix_plusPlus_parenthesized() {
- super
- .test_illegalAssignmentToNonAssignable_postfix_plusPlus_parenthesized();
- }
-
- @failingTest
- void test_illegalAssignmentToNonAssignable_primarySelectorPostfix() {
- super.test_illegalAssignmentToNonAssignable_primarySelectorPostfix();
- }
-
- @failingTest
- void test_illegalAssignmentToNonAssignable_superAssigned() {
- super.test_illegalAssignmentToNonAssignable_superAssigned();
- }
-
- @failingTest
- void test_implementsBeforeExtends() {
- super.test_implementsBeforeExtends();
- }
-
- @failingTest
- void test_implementsBeforeWith() {
- super.test_implementsBeforeWith();
- }
-
- @failingTest
- void test_importDirectiveAfterPartDirective() {
- super.test_importDirectiveAfterPartDirective();
- }
-
- @failingTest
- void test_initializedVariableInForEach() {
- super.test_initializedVariableInForEach();
- }
-
- @failingTest
- void test_initializedVariableInForEach_annotation() {
- super.test_initializedVariableInForEach_annotation();
- }
-
- @failingTest
- void test_initializedVariableInForEach_localFunction() {
- super.test_initializedVariableInForEach_localFunction();
- }
-
- @failingTest
- void test_initializedVariableInForEach_localFunction2() {
- super.test_initializedVariableInForEach_localFunction2();
- }
-
- @failingTest
- void test_initializedVariableInForEach_var() {
- super.test_initializedVariableInForEach_var();
- }
-
- @failingTest
- void test_invalidAwaitInFor() {
- super.test_invalidAwaitInFor();
- }
-
- @failingTest
- void test_invalidCommentReference__new_nonIdentifier() {
- super.test_invalidCommentReference__new_nonIdentifier();
- }
-
- @failingTest
- void test_invalidCommentReference__new_tooMuch() {
- super.test_invalidCommentReference__new_tooMuch();
- }
-
- @failingTest
- void test_invalidCommentReference__nonNew_nonIdentifier() {
- super.test_invalidCommentReference__nonNew_nonIdentifier();
- }
-
- @failingTest
- void test_invalidCommentReference__nonNew_tooMuch() {
- super.test_invalidCommentReference__nonNew_tooMuch();
- }
-
- @failingTest
- void test_invalidConstructorName_star() {
- super.test_invalidConstructorName_star();
- }
-
- @failingTest
- void test_invalidConstructorName_with() {
- super.test_invalidConstructorName_with();
- }
-
- @failingTest
- void test_invalidInterpolationIdentifier_startWithDigit() {
- super.test_invalidInterpolationIdentifier_startWithDigit();
- }
-
- @failingTest
- void test_invalidLiteralInConfiguration() {
- super.test_invalidLiteralInConfiguration();
- }
-
- @failingTest
- void test_invalidOperator() {
- super.test_invalidOperator();
- }
-
- @failingTest
- void test_invalidOperator_unary() {
- super.test_invalidOperator_unary();
- }
-
- @failingTest
- void test_invalidOperatorAfterSuper_assignableExpression() {
- super.test_invalidOperatorAfterSuper_assignableExpression();
- }
-
- @failingTest
- void test_invalidOperatorAfterSuper_primaryExpression() {
- super.test_invalidOperatorAfterSuper_primaryExpression();
- }
-
- @failingTest
- void test_invalidOperatorForSuper() {
- super.test_invalidOperatorForSuper();
- }
-
- @failingTest
- void test_invalidStarAfterAsync() {
- super.test_invalidStarAfterAsync();
- }
-
- @failingTest
- void test_invalidSync() {
- super.test_invalidSync();
- }
-
- @failingTest
- void test_invalidTopLevelSetter() {
- super.test_invalidTopLevelSetter();
- }
-
- @failingTest
- void test_invalidTopLevelVar() {
- super.test_invalidTopLevelVar();
- }
-
- @failingTest
- void test_invalidTypedef() {
- super.test_invalidTypedef();
- }
-
- @failingTest
- void test_invalidTypedef2() {
- super.test_invalidTypedef2();
- }
-
- @failingTest
- void test_invalidUnicodeEscape_incomplete_noDigits() {
- super.test_invalidUnicodeEscape_incomplete_noDigits();
- }
-
- @failingTest
- void test_invalidUnicodeEscape_incomplete_someDigits() {
- super.test_invalidUnicodeEscape_incomplete_someDigits();
- }
-
- @failingTest
- void test_invalidUnicodeEscape_invalidDigit() {
- super.test_invalidUnicodeEscape_invalidDigit();
- }
-
- @failingTest
- void test_invalidUnicodeEscape_tooFewDigits_fixed() {
- super.test_invalidUnicodeEscape_tooFewDigits_fixed();
- }
-
- @failingTest
- void test_invalidUnicodeEscape_tooFewDigits_variable() {
- super.test_invalidUnicodeEscape_tooFewDigits_variable();
- }
-
- @failingTest
- void test_invalidUnicodeEscape_tooManyDigits_variable() {
- super.test_invalidUnicodeEscape_tooManyDigits_variable();
- }
-
- @failingTest
- void test_libraryDirectiveNotFirst() {
- super.test_libraryDirectiveNotFirst();
- }
-
- @failingTest
- void test_libraryDirectiveNotFirst_afterPart() {
- super.test_libraryDirectiveNotFirst_afterPart();
- }
-
- @failingTest
- void test_localFunction_annotation() {
- super.test_localFunction_annotation();
- }
-
- @failingTest
- void test_localFunctionDeclarationModifier_abstract() {
- super.test_localFunctionDeclarationModifier_abstract();
- }
-
- @failingTest
- void test_localFunctionDeclarationModifier_external() {
- super.test_localFunctionDeclarationModifier_external();
- }
-
- @failingTest
- void test_localFunctionDeclarationModifier_factory() {
- super.test_localFunctionDeclarationModifier_factory();
- }
-
- @failingTest
- void test_localFunctionDeclarationModifier_static() {
- super.test_localFunctionDeclarationModifier_static();
- }
-
- @failingTest
- void test_method_invalidTypeParameterComments() {
- super.test_method_invalidTypeParameterComments();
- }
-
- @failingTest
- void test_method_invalidTypeParameterExtends() {
- super.test_method_invalidTypeParameterExtends();
- }
-
- @failingTest
- void test_method_invalidTypeParameterExtendsComment() {
- super.test_method_invalidTypeParameterExtendsComment();
- }
-
- @failingTest
- void test_method_invalidTypeParameters() {
- super.test_method_invalidTypeParameters();
- }
-
- @failingTest
- void test_missingAssignableSelector_identifiersAssigned() {
- super.test_missingAssignableSelector_identifiersAssigned();
- dart2Failure();
- }
-
- @failingTest
- void test_missingAssignableSelector_prefix_minusMinus_literal() {
- super.test_missingAssignableSelector_prefix_minusMinus_literal();
- }
-
- @failingTest
- void test_missingAssignableSelector_prefix_plusPlus_literal() {
- super.test_missingAssignableSelector_prefix_plusPlus_literal();
- }
-
- @failingTest
- void test_missingAssignableSelector_selector() {
- super.test_missingAssignableSelector_selector();
- }
-
- @failingTest
- void test_missingAssignableSelector_superPrimaryExpression() {
- super.test_missingAssignableSelector_superPrimaryExpression();
- }
-
- @failingTest
- void test_missingAssignableSelector_superPropertyAccessAssigned() {
- super.test_missingAssignableSelector_superPropertyAccessAssigned();
- dart2Failure();
- }
-
- @failingTest
- void test_missingCatchOrFinally() {
- super.test_missingCatchOrFinally();
- }
-
- @failingTest
- void test_missingClassBody() {
- super.test_missingClassBody();
- }
-
- @failingTest
- void test_missingClosingParenthesis() {
- super.test_missingClosingParenthesis();
- }
-
- @failingTest
- void test_missingConstFinalVarOrType_static() {
- super.test_missingConstFinalVarOrType_static();
- }
-
- @failingTest
- void test_missingConstFinalVarOrType_topLevel() {
- super.test_missingConstFinalVarOrType_topLevel();
- }
-
- @failingTest
- void test_missingEnumBody() {
- super.test_missingEnumBody();
- }
-
- @failingTest
- void test_missingEnumComma() {
- super.test_missingEnumComma();
- }
-
- @failingTest
- void test_missingExpressionInThrow() {
- super.test_missingExpressionInThrow();
- }
-
- @failingTest
- void test_missingFunctionBody_emptyNotAllowed() {
- super.test_missingFunctionBody_emptyNotAllowed();
- }
-
- @failingTest
- void test_missingFunctionBody_invalid() {
- super.test_missingFunctionBody_invalid();
- }
-
- @failingTest
- void test_missingFunctionParameters_local_nonVoid_block() {
- super.test_missingFunctionParameters_local_nonVoid_block();
- }
-
- @failingTest
- void test_missingFunctionParameters_local_nonVoid_expression() {
- super.test_missingFunctionParameters_local_nonVoid_expression();
- }
-
- @failingTest
- void test_missingFunctionParameters_local_void_block() {
- super.test_missingFunctionParameters_local_void_block();
- }
-
- @failingTest
- void test_missingFunctionParameters_local_void_expression() {
- super.test_missingFunctionParameters_local_void_expression();
- }
-
- @failingTest
- void test_missingFunctionParameters_topLevel_nonVoid_block() {
- super.test_missingFunctionParameters_topLevel_nonVoid_block();
- }
-
- @failingTest
- void test_missingFunctionParameters_topLevel_nonVoid_expression() {
- super.test_missingFunctionParameters_topLevel_nonVoid_expression();
- }
-
- @failingTest
- void test_missingFunctionParameters_topLevel_void_block() {
- super.test_missingFunctionParameters_topLevel_void_block();
- }
-
- @failingTest
- void test_missingFunctionParameters_topLevel_void_expression() {
- super.test_missingFunctionParameters_topLevel_void_expression();
- }
-
- @failingTest
- void test_missingIdentifier_afterOperator() {
- super.test_missingIdentifier_afterOperator();
- }
-
- @failingTest
- void test_missingIdentifier_beforeClosingCurly() {
- super.test_missingIdentifier_beforeClosingCurly();
- }
-
- @failingTest
- void test_missingIdentifier_inEnum() {
- super.test_missingIdentifier_inEnum();
- }
-
- @failingTest
- void test_missingIdentifier_inParameterGroupNamed() {
- super.test_missingIdentifier_inParameterGroupNamed();
- }
-
- @failingTest
- void test_missingIdentifier_inParameterGroupOptional() {
- super.test_missingIdentifier_inParameterGroupOptional();
- }
-
- @failingTest
- void test_missingIdentifier_inSymbol_afterPeriod() {
- super.test_missingIdentifier_inSymbol_afterPeriod();
- }
-
- @failingTest
- void test_missingIdentifier_inSymbol_first() {
- super.test_missingIdentifier_inSymbol_first();
- }
-
- @failingTest
- void test_missingIdentifierForParameterGroup() {
- super.test_missingIdentifierForParameterGroup();
- }
-
- @failingTest
- void test_missingKeywordOperator() {
- super.test_missingKeywordOperator();
- }
-
- @failingTest
- void test_missingKeywordOperator_parseClassMember() {
- super.test_missingKeywordOperator_parseClassMember();
- }
-
- @failingTest
- void test_missingKeywordOperator_parseClassMember_afterTypeName() {
- super.test_missingKeywordOperator_parseClassMember_afterTypeName();
- }
-
- @failingTest
- void test_missingKeywordOperator_parseClassMember_afterVoid() {
- super.test_missingKeywordOperator_parseClassMember_afterVoid();
- }
-
- @failingTest
- void test_missingMethodParameters_void_block() {
- super.test_missingMethodParameters_void_block();
- }
-
- @failingTest
- void test_missingMethodParameters_void_expression() {
- super.test_missingMethodParameters_void_expression();
- }
-
- @failingTest
- void test_missingNameForNamedParameter_colon() {
- super.test_missingNameForNamedParameter_colon();
- }
-
- @failingTest
- void test_missingNameForNamedParameter_equals() {
- super.test_missingNameForNamedParameter_equals();
- }
-
- @failingTest
- void test_missingNameForNamedParameter_noDefault() {
- super.test_missingNameForNamedParameter_noDefault();
- }
-
- @failingTest
- void test_missingNameInLibraryDirective() {
- super.test_missingNameInLibraryDirective();
- }
-
- @failingTest
- void test_missingNameInPartOfDirective() {
- super.test_missingNameInPartOfDirective();
- }
-
- @failingTest
- void test_missingPrefixInDeferredImport() {
- super.test_missingPrefixInDeferredImport();
- }
-
- @failingTest
- void test_missingStartAfterSync() {
- super.test_missingStartAfterSync();
- }
-
- @failingTest
- void test_missingStatement() {
- super.test_missingStatement();
- }
-
- @failingTest
- void test_missingStatement_afterVoid() {
- super.test_missingStatement_afterVoid();
- }
-
- @failingTest
- void test_missingTerminatorForParameterGroup_named() {
- super.test_missingTerminatorForParameterGroup_named();
- }
-
- @failingTest
- void test_missingTerminatorForParameterGroup_optional() {
- super.test_missingTerminatorForParameterGroup_optional();
- }
-
- @failingTest
- void test_missingTypedefParameters_nonVoid() {
- super.test_missingTypedefParameters_nonVoid();
- }
-
- @failingTest
- void test_missingTypedefParameters_typeParameters() {
- super.test_missingTypedefParameters_typeParameters();
- }
-
- @failingTest
- void test_missingTypedefParameters_void() {
- super.test_missingTypedefParameters_void();
- }
-
- @failingTest
- void test_missingVariableInForEach() {
- super.test_missingVariableInForEach();
- }
-
- @failingTest
- void test_mixedParameterGroups_namedPositional() {
- super.test_mixedParameterGroups_namedPositional();
- }
-
- @failingTest
- void test_mixedParameterGroups_positionalNamed() {
- super.test_mixedParameterGroups_positionalNamed();
- }
-
- @failingTest
- void test_mixin_application_lacks_with_clause() {
- super.test_mixin_application_lacks_with_clause();
- }
-
- @failingTest
- void test_multipleExtendsClauses() {
- super.test_multipleExtendsClauses();
- }
-
- @failingTest
- void test_multipleImplementsClauses() {
- super.test_multipleImplementsClauses();
- }
-
- @failingTest
- void test_multipleLibraryDirectives() {
- super.test_multipleLibraryDirectives();
- }
-
- @failingTest
- void test_multipleNamedParameterGroups() {
- super.test_multipleNamedParameterGroups();
- }
-
- @failingTest
- void test_multiplePartOfDirectives() {
- super.test_multiplePartOfDirectives();
- }
-
- @failingTest
- void test_multiplePositionalParameterGroups() {
- super.test_multiplePositionalParameterGroups();
- }
-
- @failingTest
- void test_multipleVariablesInForEach() {
- super.test_multipleVariablesInForEach();
- }
-
- @failingTest
- void test_multipleWithClauses() {
- super.test_multipleWithClauses();
- }
-
- @failingTest
- void test_namedFunctionExpression() {
- super.test_namedFunctionExpression();
- }
-
- @failingTest
- void test_namedParameterOutsideGroup() {
- super.test_namedParameterOutsideGroup();
- }
-
- @failingTest
- void test_nonConstructorFactory_field() {
- super.test_nonConstructorFactory_field();
- }
-
- @failingTest
- void test_nonConstructorFactory_method() {
- super.test_nonConstructorFactory_method();
- }
-
- @failingTest
- void test_nonIdentifierLibraryName_library() {
- super.test_nonIdentifierLibraryName_library();
- }
-
- @failingTest
- void test_nonIdentifierLibraryName_partOf() {
- super.test_nonIdentifierLibraryName_partOf();
- }
-
- @failingTest
- void test_nonPartOfDirectiveInPart_after() {
- super.test_nonPartOfDirectiveInPart_after();
- }
-
- @failingTest
- void test_nonPartOfDirectiveInPart_before() {
- super.test_nonPartOfDirectiveInPart_before();
- }
-
- @failingTest
- void test_nonUserDefinableOperator() {
- super.test_nonUserDefinableOperator();
- }
-
- @failingTest
- void test_optionalAfterNormalParameters_named() {
- super.test_optionalAfterNormalParameters_named();
- }
-
- @failingTest
- void test_optionalAfterNormalParameters_positional() {
- super.test_optionalAfterNormalParameters_positional();
- }
-
- @failingTest
- void test_parseCascadeSection_missingIdentifier() {
- super.test_parseCascadeSection_missingIdentifier();
- }
-
- @failingTest
- void test_parseCascadeSection_missingIdentifier_typeArguments() {
- super.test_parseCascadeSection_missingIdentifier_typeArguments();
- }
-
- @failingTest
- void test_positionalAfterNamedArgument() {
- super.test_positionalAfterNamedArgument();
- }
-
- @failingTest
- void test_positionalParameterOutsideGroup() {
- super.test_positionalParameterOutsideGroup();
- }
-
- @failingTest
- void test_redirectingConstructorWithBody_named() {
- super.test_redirectingConstructorWithBody_named();
- }
-
- @failingTest
- void test_redirectingConstructorWithBody_unnamed() {
- super.test_redirectingConstructorWithBody_unnamed();
- }
-
- @failingTest
- void test_redirectionInNonFactoryConstructor() {
- super.test_redirectionInNonFactoryConstructor();
- }
-
- @failingTest
- void test_setterInFunction_block() {
- super.test_setterInFunction_block();
- }
-
- @failingTest
- void test_setterInFunction_expression() {
- super.test_setterInFunction_expression();
- }
-
- @failingTest
- void test_staticAfterConst() {
- super.test_staticAfterConst();
- }
-
- @failingTest
- void test_staticAfterFinal() {
- super.test_staticAfterFinal();
- }
-
- @failingTest
- void test_staticAfterVar() {
- super.test_staticAfterVar();
- }
-
- @failingTest
- void test_staticConstructor() {
- super.test_staticConstructor();
- }
-
- @failingTest
- void test_staticGetterWithoutBody() {
- super.test_staticGetterWithoutBody();
- }
-
- @failingTest
- void test_staticOperator_noReturnType() {
- super.test_staticOperator_noReturnType();
- }
-
- @failingTest
- void test_staticOperator_returnType() {
- super.test_staticOperator_returnType();
- }
-
- @failingTest
- void test_staticSetterWithoutBody() {
- super.test_staticSetterWithoutBody();
- }
-
- @failingTest
- void test_staticTopLevelDeclaration_class() {
- super.test_staticTopLevelDeclaration_class();
- }
-
- @failingTest
- void test_staticTopLevelDeclaration_enum() {
- super.test_staticTopLevelDeclaration_enum();
- }
-
- @failingTest
- void test_staticTopLevelDeclaration_function() {
- super.test_staticTopLevelDeclaration_function();
- }
-
- @failingTest
- void test_staticTopLevelDeclaration_typedef() {
- super.test_staticTopLevelDeclaration_typedef();
- }
-
- @failingTest
- void test_staticTopLevelDeclaration_variable() {
- super.test_staticTopLevelDeclaration_variable();
- }
-
- @failingTest
- void test_string_unterminated_interpolation_block() {
- super.test_string_unterminated_interpolation_block();
- }
-
- @failingTest
- void test_switchCase_missingColon() {
- super.test_switchCase_missingColon();
- }
-
- @failingTest
- void test_switchDefault_missingColon() {
- super.test_switchDefault_missingColon();
- }
-
- @failingTest
- void test_switchHasCaseAfterDefaultCase() {
- super.test_switchHasCaseAfterDefaultCase();
- }
-
- @failingTest
- void test_switchHasCaseAfterDefaultCase_repeated() {
- super.test_switchHasCaseAfterDefaultCase_repeated();
- }
-
- @failingTest
- void test_switchHasMultipleDefaultCases() {
- super.test_switchHasMultipleDefaultCases();
- }
-
- @failingTest
- void test_switchHasMultipleDefaultCases_repeated() {
- super.test_switchHasMultipleDefaultCases_repeated();
- }
-
- @failingTest
- void test_switchMissingBlock() {
- super.test_switchMissingBlock();
- }
-
- @failingTest
- void test_topLevel_getter() {
- super.test_topLevel_getter();
- }
-
- @failingTest
- void test_topLevelFactory_withFunction() {
- super.test_topLevelFactory_withFunction();
- }
-
- @failingTest
- void test_topLevelOperator_withFunction() {
- super.test_topLevelOperator_withFunction();
- }
-
- @failingTest
- void test_topLevelOperator_withoutOperator() {
- super.test_topLevelOperator_withoutOperator();
- }
-
- @failingTest
- void test_topLevelOperator_withoutType() {
- super.test_topLevelOperator_withoutType();
- }
-
- @failingTest
- void test_topLevelOperator_withType() {
- super.test_topLevelOperator_withType();
- }
-
- @failingTest
- void test_topLevelOperator_withVoid() {
- super.test_topLevelOperator_withVoid();
- }
-
- @failingTest
- void test_topLevelVariable_withMetadata() {
- super.test_topLevelVariable_withMetadata();
- }
-
- @failingTest
- void test_typedef_incomplete() {
- super.test_typedef_incomplete();
- }
-
- @failingTest
- void test_typedef_namedFunction() {
- super.test_typedef_namedFunction();
- }
-
- @failingTest
- void test_typedefInClass_withoutReturnType() {
- super.test_typedefInClass_withoutReturnType();
- }
-
- @failingTest
- void test_typedefInClass_withReturnType() {
- super.test_typedefInClass_withReturnType();
- }
-
- @failingTest
- void test_unexpectedTerminatorForParameterGroup_named() {
- super.test_unexpectedTerminatorForParameterGroup_named();
- }
-
- @failingTest
- void test_unexpectedTerminatorForParameterGroup_optional() {
- super.test_unexpectedTerminatorForParameterGroup_optional();
- }
-
- @failingTest
- void test_unexpectedToken_endOfFieldDeclarationStatement() {
- super.test_unexpectedToken_endOfFieldDeclarationStatement();
- }
-
- @failingTest
- void test_unexpectedToken_invalidPostfixExpression() {
- super.test_unexpectedToken_invalidPostfixExpression();
- }
-
- @failingTest
- void test_unexpectedToken_invalidPrefixExpression() {
- super.test_unexpectedToken_invalidPrefixExpression();
- }
-
- @failingTest
- void test_unexpectedToken_returnInExpressionFunctionBody() {
- super.test_unexpectedToken_returnInExpressionFunctionBody();
- }
-
- @failingTest
- void test_unexpectedToken_semicolonBetweenClassMembers() {
- super.test_unexpectedToken_semicolonBetweenClassMembers();
- }
-
- @failingTest
- void test_unexpectedToken_semicolonBetweenCompilationUnitMembers() {
- super.test_unexpectedToken_semicolonBetweenCompilationUnitMembers();
- }
-
- @failingTest
- void test_unterminatedString_at_eof() {
- super.test_unterminatedString_at_eof();
- }
-
- @failingTest
- void test_unterminatedString_at_eol() {
- super.test_unterminatedString_at_eol();
- }
-
- @failingTest
- void test_unterminatedString_multiline_at_eof_3_quotes() {
- super.test_unterminatedString_multiline_at_eof_3_quotes();
- }
-
- @failingTest
- void test_unterminatedString_multiline_at_eof_4_quotes() {
- super.test_unterminatedString_multiline_at_eof_4_quotes();
- }
-
- @failingTest
- void test_unterminatedString_multiline_at_eof_5_quotes() {
- super.test_unterminatedString_multiline_at_eof_5_quotes();
- }
-
- @failingTest
- void test_useOfUnaryPlusOperator() {
- super.test_useOfUnaryPlusOperator();
- }
-
- @failingTest
- void test_varAndType_field() {
- super.test_varAndType_field();
- }
-
- @failingTest
- void test_varAndType_local() {
- super.test_varAndType_local();
- }
-
- @failingTest
- void test_varAndType_parameter() {
- super.test_varAndType_parameter();
- }
-
- @failingTest
- void test_varAndType_topLevelVariable() {
- super.test_varAndType_topLevelVariable();
- }
-
- @failingTest
- void test_varAsTypeName_as() {
- super.test_varAsTypeName_as();
- }
-
- @failingTest
- void test_varClass() {
- super.test_varClass();
- }
-
- @failingTest
- void test_varEnum() {
- super.test_varEnum();
- }
-
- @failingTest
- void test_varReturnType() {
- super.test_varReturnType();
- }
-
- @failingTest
- void test_varTypedef() {
- super.test_varTypedef();
- }
-
- @failingTest
- void test_voidParameter() {
- super.test_voidParameter();
- }
-
- @failingTest
- void test_voidVariable_parseClassMember_initializer() {
- super.test_voidVariable_parseClassMember_initializer();
- }
-
- @failingTest
- void test_voidVariable_parseClassMember_noInitializer() {
- super.test_voidVariable_parseClassMember_noInitializer();
- }
-
- @failingTest
- void test_voidVariable_parseCompilationUnit_initializer() {
- super.test_voidVariable_parseCompilationUnit_initializer();
- }
-
- @failingTest
- void test_voidVariable_parseCompilationUnit_noInitializer() {
- super.test_voidVariable_parseCompilationUnit_noInitializer();
- }
-
- @failingTest
- void test_voidVariable_parseCompilationUnitMember_initializer() {
- super.test_voidVariable_parseCompilationUnitMember_initializer();
- }
-
- @failingTest
- void test_voidVariable_parseCompilationUnitMember_noInitializer() {
- super.test_voidVariable_parseCompilationUnitMember_noInitializer();
- }
-
- @failingTest
- void test_voidVariable_statement_initializer() {
- super.test_voidVariable_statement_initializer();
- }
-
- @failingTest
- void test_voidVariable_statement_noInitializer() {
- super.test_voidVariable_statement_noInitializer();
- }
-
- @failingTest
- void test_withBeforeExtends() {
- super.test_withBeforeExtends();
- }
-
- @failingTest
- void test_withWithoutExtends() {
- super.test_withWithoutExtends();
- }
-
- @failingTest
- void test_wrongSeparatorForPositionalParameter() {
- super.test_wrongSeparatorForPositionalParameter();
- }
-
- @failingTest
- void test_wrongTerminatorForParameterGroup_named() {
- super.test_wrongTerminatorForParameterGroup_named();
- }
-
- @failingTest
- void test_wrongTerminatorForParameterGroup_optional() {
- super.test_wrongTerminatorForParameterGroup_optional();
- }
-}
-
-@reflectiveTest
-class ExpressionParserTest_Forest extends FastaBodyBuilderTestCase
- with ExpressionParserTestMixin {
- ExpressionParserTest_Forest() : super(false);
-
- @failingTest
- void test_namedArgument() {
- super.test_namedArgument();
- }
-
- @failingTest
- void test_parseAdditiveExpression_normal() {
- super.test_parseAdditiveExpression_normal();
- }
-
- @failingTest
- void test_parseAdditiveExpression_super() {
- super.test_parseAdditiveExpression_super();
- }
-
- @failingTest
- void test_parseAssignableExpression_expression_args_dot() {
- super.test_parseAssignableExpression_expression_args_dot();
- }
-
- @failingTest
- void
- test_parseAssignableExpression_expression_args_dot_typeArgumentComments() {
- super
- .test_parseAssignableExpression_expression_args_dot_typeArgumentComments();
- }
-
- @failingTest
- void test_parseAssignableExpression_expression_args_dot_typeArguments() {
- super.test_parseAssignableExpression_expression_args_dot_typeArguments();
- }
-
- @failingTest
- void test_parseAssignableExpression_expression_dot() {
- super.test_parseAssignableExpression_expression_dot();
- }
-
- @failingTest
- void test_parseAssignableExpression_expression_index() {
- super.test_parseAssignableExpression_expression_index();
- dart2Failure();
- }
-
- @failingTest
- void test_parseAssignableExpression_expression_question_dot() {
- super.test_parseAssignableExpression_expression_question_dot();
- }
-
- @failingTest
- void test_parseAssignableExpression_identifier_args_dot() {
- super.test_parseAssignableExpression_identifier_args_dot();
- }
-
- @failingTest
- void
- test_parseAssignableExpression_identifier_args_dot_typeArgumentComments() {
- super
- .test_parseAssignableExpression_identifier_args_dot_typeArgumentComments();
- }
-
- @failingTest
- void test_parseAssignableExpression_identifier_args_dot_typeArguments() {
- super.test_parseAssignableExpression_identifier_args_dot_typeArguments();
- }
-
- @failingTest
- void test_parseAssignableExpression_identifier_dot() {
- super.test_parseAssignableExpression_identifier_dot();
- }
-
- @failingTest
- void test_parseAssignableExpression_identifier_question_dot() {
- super.test_parseAssignableExpression_identifier_question_dot();
- }
-
- @failingTest
- void test_parseAssignableExpression_super_dot() {
- super.test_parseAssignableExpression_super_dot();
- }
-
- @failingTest
- void test_parseAssignableExpression_super_index() {
- super.test_parseAssignableExpression_super_index();
- }
-
- @failingTest
- void test_parseAssignableSelector_dot() {
- super.test_parseAssignableSelector_dot();
- }
-
- @failingTest
- void test_parseAssignableSelector_index() {
- super.test_parseAssignableSelector_index();
- }
-
- @failingTest
- void test_parseAssignableSelector_question_dot() {
- super.test_parseAssignableSelector_question_dot();
- }
-
- @failingTest
- void test_parseBitwiseAndExpression_normal() {
- super.test_parseBitwiseAndExpression_normal();
- }
-
- @failingTest
- void test_parseBitwiseAndExpression_super() {
- super.test_parseBitwiseAndExpression_super();
- }
-
- @failingTest
- void test_parseBitwiseOrExpression_normal() {
- super.test_parseBitwiseOrExpression_normal();
- }
-
- @failingTest
- void test_parseBitwiseOrExpression_super() {
- super.test_parseBitwiseOrExpression_super();
- }
-
- @failingTest
- void test_parseBitwiseXorExpression_normal() {
- super.test_parseBitwiseXorExpression_normal();
- }
-
- @failingTest
- void test_parseBitwiseXorExpression_super() {
- super.test_parseBitwiseXorExpression_super();
- }
-
- @failingTest
- void test_parseCascadeSection_i() {
- super.test_parseCascadeSection_i();
- }
-
- @failingTest
- void test_parseCascadeSection_ia() {
- super.test_parseCascadeSection_ia();
- }
-
- @failingTest
- void test_parseCascadeSection_ia_typeArgumentComments() {
- super.test_parseCascadeSection_ia_typeArgumentComments();
- }
-
- @failingTest
- void test_parseCascadeSection_ia_typeArguments() {
- super.test_parseCascadeSection_ia_typeArguments();
- }
-
- @failingTest
- void test_parseCascadeSection_ii() {
- super.test_parseCascadeSection_ii();
- }
-
- @failingTest
- void test_parseCascadeSection_ii_typeArgumentComments() {
- super.test_parseCascadeSection_ii_typeArgumentComments();
- }
-
- @failingTest
- void test_parseCascadeSection_ii_typeArguments() {
- super.test_parseCascadeSection_ii_typeArguments();
- }
-
- @failingTest
- void test_parseCascadeSection_p() {
- super.test_parseCascadeSection_p();
- }
-
- @failingTest
- void test_parseCascadeSection_p_assign() {
- super.test_parseCascadeSection_p_assign();
- }
-
- @failingTest
- void test_parseCascadeSection_p_assign_withCascade() {
- super.test_parseCascadeSection_p_assign_withCascade();
- }
-
- @failingTest
- void test_parseCascadeSection_p_assign_withCascade_typeArgumentComments() {
- super.test_parseCascadeSection_p_assign_withCascade_typeArgumentComments();
- }
-
- @failingTest
- void test_parseCascadeSection_p_assign_withCascade_typeArguments() {
- super.test_parseCascadeSection_p_assign_withCascade_typeArguments();
- }
-
- @failingTest
- void test_parseCascadeSection_p_builtIn() {
- super.test_parseCascadeSection_p_builtIn();
- }
-
- @failingTest
- void test_parseCascadeSection_pa() {
- super.test_parseCascadeSection_pa();
- }
-
- @failingTest
- void test_parseCascadeSection_pa_typeArgumentComments() {
- super.test_parseCascadeSection_pa_typeArgumentComments();
- }
-
- @failingTest
- void test_parseCascadeSection_pa_typeArguments() {
- super.test_parseCascadeSection_pa_typeArguments();
- }
-
- @failingTest
- void test_parseCascadeSection_paa() {
- super.test_parseCascadeSection_paa();
- }
-
- @failingTest
- void test_parseCascadeSection_paa_typeArgumentComments() {
- super.test_parseCascadeSection_paa_typeArgumentComments();
- }
-
- @failingTest
- void test_parseCascadeSection_paa_typeArguments() {
- super.test_parseCascadeSection_paa_typeArguments();
- }
-
- @failingTest
- void test_parseCascadeSection_paapaa() {
- super.test_parseCascadeSection_paapaa();
- }
-
- @failingTest
- void test_parseCascadeSection_paapaa_typeArgumentComments() {
- super.test_parseCascadeSection_paapaa_typeArgumentComments();
- }
-
- @failingTest
- void test_parseCascadeSection_paapaa_typeArguments() {
- super.test_parseCascadeSection_paapaa_typeArguments();
- }
-
- @failingTest
- void test_parseCascadeSection_pap() {
- super.test_parseCascadeSection_pap();
- }
-
- @failingTest
- void test_parseCascadeSection_pap_typeArgumentComments() {
- super.test_parseCascadeSection_pap_typeArgumentComments();
- }
-
- @failingTest
- void test_parseCascadeSection_pap_typeArguments() {
- super.test_parseCascadeSection_pap_typeArguments();
- }
-
- @failingTest
- void test_parseConditionalExpression() {
- super.test_parseConditionalExpression();
- dart2Failure();
- }
-
- @failingTest
- void test_parseConstExpression_instanceCreation() {
- super.test_parseConstExpression_instanceCreation();
- }
-
- @failingTest
- void test_parseConstExpression_listLiteral_typed() {
- super.test_parseConstExpression_listLiteral_typed();
- }
-
- @failingTest
- void test_parseConstExpression_listLiteral_typed_genericComment() {
- super.test_parseConstExpression_listLiteral_typed_genericComment();
- }
-
- @failingTest
- void test_parseConstExpression_mapLiteral_typed() {
- super.test_parseConstExpression_mapLiteral_typed();
- }
-
- @failingTest
- void test_parseConstExpression_mapLiteral_typed_genericComment() {
- super.test_parseConstExpression_mapLiteral_typed_genericComment();
- }
-
- @failingTest
- void test_parseEqualityExpression_normal() {
- super.test_parseEqualityExpression_normal();
- }
-
- @failingTest
- void test_parseEqualityExpression_super() {
- super.test_parseEqualityExpression_super();
- }
-
- @failingTest
- void test_parseExpression_assign() {
- super.test_parseExpression_assign();
- }
-
- @failingTest
- void test_parseExpression_comparison() {
- super.test_parseExpression_comparison();
- }
-
- @failingTest
- void test_parseExpression_function_async() {
- super.test_parseExpression_function_async();
- }
-
- @failingTest
- void test_parseExpression_function_asyncStar() {
- super.test_parseExpression_function_asyncStar();
- }
-
- @failingTest
- void test_parseExpression_function_sync() {
- super.test_parseExpression_function_sync();
- }
-
- @failingTest
- void test_parseExpression_function_syncStar() {
- super.test_parseExpression_function_syncStar();
- }
-
- @failingTest
- void test_parseExpression_invokeFunctionExpression() {
- super.test_parseExpression_invokeFunctionExpression();
- }
-
- @failingTest
- void test_parseExpression_nonAwait() {
- super.test_parseExpression_nonAwait();
- }
-
- @failingTest
- void test_parseExpression_superMethodInvocation() {
- super.test_parseExpression_superMethodInvocation();
- }
-
- @failingTest
- void test_parseExpression_superMethodInvocation_typeArgumentComments() {
- super.test_parseExpression_superMethodInvocation_typeArgumentComments();
- }
-
- @failingTest
- void test_parseExpression_superMethodInvocation_typeArguments() {
- super.test_parseExpression_superMethodInvocation_typeArguments();
- }
-
- @failingTest
- void test_parseExpression_superMethodInvocation_typeArguments_chained() {
- super.test_parseExpression_superMethodInvocation_typeArguments_chained();
- }
-
- @failingTest
- void test_parseExpressionList_multiple() {
- super.test_parseExpressionList_multiple();
- }
-
- @failingTest
- void test_parseExpressionList_single() {
- super.test_parseExpressionList_single();
- }
-
- @failingTest
- void test_parseExpressionWithoutCascade_assign() {
- super.test_parseExpressionWithoutCascade_assign();
- }
-
- @failingTest
- void test_parseExpressionWithoutCascade_comparison() {
- super.test_parseExpressionWithoutCascade_comparison();
- }
-
- @failingTest
- void test_parseExpressionWithoutCascade_superMethodInvocation() {
- super.test_parseExpressionWithoutCascade_superMethodInvocation();
- }
-
- @failingTest
- void
- test_parseExpressionWithoutCascade_superMethodInvocation_typeArgumentComments() {
- super
- .test_parseExpressionWithoutCascade_superMethodInvocation_typeArgumentComments();
- }
-
- @failingTest
- void
- test_parseExpressionWithoutCascade_superMethodInvocation_typeArguments() {
- super
- .test_parseExpressionWithoutCascade_superMethodInvocation_typeArguments();
- }
-
- @failingTest
- void test_parseFunctionExpression_body_inExpression() {
- super.test_parseFunctionExpression_body_inExpression();
- }
-
- @failingTest
- void test_parseFunctionExpression_typeParameterComments() {
- super.test_parseFunctionExpression_typeParameterComments();
- }
-
- @failingTest
- void test_parseFunctionExpression_typeParameters() {
- super.test_parseFunctionExpression_typeParameters();
- }
-
- @failingTest
- void test_parseInstanceCreationExpression_qualifiedType() {
- super.test_parseInstanceCreationExpression_qualifiedType();
- }
-
- @failingTest
- void test_parseInstanceCreationExpression_qualifiedType_named() {
- super.test_parseInstanceCreationExpression_qualifiedType_named();
- }
-
- @failingTest
- void
- test_parseInstanceCreationExpression_qualifiedType_named_typeArgumentComments() {
- super
- .test_parseInstanceCreationExpression_qualifiedType_named_typeArgumentComments();
- }
-
- @failingTest
- void
- test_parseInstanceCreationExpression_qualifiedType_named_typeArguments() {
- super
- .test_parseInstanceCreationExpression_qualifiedType_named_typeArguments();
- }
-
- @failingTest
- void
- test_parseInstanceCreationExpression_qualifiedType_typeArgumentComments() {
- super
- .test_parseInstanceCreationExpression_qualifiedType_typeArgumentComments();
- }
-
- @failingTest
- void test_parseInstanceCreationExpression_qualifiedType_typeArguments() {
- super.test_parseInstanceCreationExpression_qualifiedType_typeArguments();
- }
-
- @failingTest
- void test_parseInstanceCreationExpression_type() {
- super.test_parseInstanceCreationExpression_type();
- }
-
- @failingTest
- void test_parseInstanceCreationExpression_type_named() {
- super.test_parseInstanceCreationExpression_type_named();
- }
-
- @failingTest
- void test_parseInstanceCreationExpression_type_named_typeArgumentComments() {
- super
- .test_parseInstanceCreationExpression_type_named_typeArgumentComments();
- }
-
- @failingTest
- void test_parseInstanceCreationExpression_type_named_typeArguments() {
- super.test_parseInstanceCreationExpression_type_named_typeArguments();
- }
-
- @failingTest
- void test_parseInstanceCreationExpression_type_typeArgumentComments() {
- super.test_parseInstanceCreationExpression_type_typeArgumentComments();
- }
-
- @failingTest
- void test_parseInstanceCreationExpression_type_typeArguments() {
- super.test_parseInstanceCreationExpression_type_typeArguments();
- }
-
- @failingTest
- void test_parseListLiteral_empty_oneToken_withComment() {
- super.test_parseListLiteral_empty_oneToken_withComment();
- }
-
- @failingTest
- void test_parseListLiteral_single_withTypeArgument() {
- super.test_parseListLiteral_single_withTypeArgument();
- }
-
- @failingTest
- void test_parseListOrMapLiteral_list_type() {
- super.test_parseListOrMapLiteral_list_type();
- }
-
- @failingTest
- void test_parseListOrMapLiteral_map_type() {
- super.test_parseListOrMapLiteral_map_type();
- }
-
- @failingTest
- void test_parseLogicalAndExpression() {
- super.test_parseLogicalAndExpression();
- dart2Failure();
- }
-
- @failingTest
- void test_parseLogicalOrExpression() {
- super.test_parseLogicalOrExpression();
- dart2Failure();
- }
-
- @failingTest
- void test_parseMapLiteral_empty() {
- super.test_parseMapLiteral_empty();
- }
-
- @failingTest
- void test_parseMapLiteralEntry_complex() {
- super.test_parseMapLiteralEntry_complex();
- }
-
- @failingTest
- void test_parseMultiplicativeExpression_normal() {
- super.test_parseMultiplicativeExpression_normal();
- }
-
- @failingTest
- void test_parseMultiplicativeExpression_super() {
- super.test_parseMultiplicativeExpression_super();
- }
-
- @failingTest
- void test_parseNewExpression() {
- super.test_parseNewExpression();
- }
-
- @failingTest
- void test_parsePostfixExpression_decrement() {
- super.test_parsePostfixExpression_decrement();
- }
-
- @failingTest
- void test_parsePostfixExpression_increment() {
- super.test_parsePostfixExpression_increment();
- }
-
- @failingTest
- void test_parsePostfixExpression_none_methodInvocation() {
- super.test_parsePostfixExpression_none_methodInvocation();
- }
-
- @failingTest
- void test_parsePostfixExpression_none_methodInvocation_question_dot() {
- super.test_parsePostfixExpression_none_methodInvocation_question_dot();
- }
-
- @failingTest
- void
- test_parsePostfixExpression_none_methodInvocation_question_dot_typeArgumentComments() {
- super
- .test_parsePostfixExpression_none_methodInvocation_question_dot_typeArgumentComments();
- }
-
- @failingTest
- void
- test_parsePostfixExpression_none_methodInvocation_question_dot_typeArguments() {
- super
- .test_parsePostfixExpression_none_methodInvocation_question_dot_typeArguments();
- }
-
- @failingTest
- void
- test_parsePostfixExpression_none_methodInvocation_typeArgumentComments() {
- super
- .test_parsePostfixExpression_none_methodInvocation_typeArgumentComments();
- }
-
- @failingTest
- void test_parsePostfixExpression_none_methodInvocation_typeArguments() {
- super.test_parsePostfixExpression_none_methodInvocation_typeArguments();
- }
-
- @failingTest
- void test_parsePostfixExpression_none_propertyAccess() {
- super.test_parsePostfixExpression_none_propertyAccess();
- }
-
- @failingTest
- void test_parsePrefixedIdentifier_prefix() {
- super.test_parsePrefixedIdentifier_prefix();
- }
-
- @failingTest
- void test_parsePrimaryExpression_const() {
- super.test_parsePrimaryExpression_const();
- dart2Failure();
- }
-
- @failingTest
- void test_parsePrimaryExpression_function_arguments() {
- super.test_parsePrimaryExpression_function_arguments();
- }
-
- @failingTest
- void test_parsePrimaryExpression_function_noArguments() {
- super.test_parsePrimaryExpression_function_noArguments();
- }
-
- @failingTest
- void test_parsePrimaryExpression_genericFunctionExpression() {
- super.test_parsePrimaryExpression_genericFunctionExpression();
- }
-
- @failingTest
- void test_parsePrimaryExpression_listLiteral_typed() {
- super.test_parsePrimaryExpression_listLiteral_typed();
- }
-
- @failingTest
- void test_parsePrimaryExpression_listLiteral_typed_genericComment() {
- super.test_parsePrimaryExpression_listLiteral_typed_genericComment();
- }
-
- @failingTest
- void test_parsePrimaryExpression_mapLiteral_typed() {
- super.test_parsePrimaryExpression_mapLiteral_typed();
- }
-
- @failingTest
- void test_parsePrimaryExpression_mapLiteral_typed_genericComment() {
- super.test_parsePrimaryExpression_mapLiteral_typed_genericComment();
- }
-
- @failingTest
- void test_parsePrimaryExpression_new() {
- super.test_parsePrimaryExpression_new();
- }
-
- @failingTest
- void test_parsePrimaryExpression_parenthesized() {
- super.test_parsePrimaryExpression_parenthesized();
- }
-
- @failingTest
- void test_parsePrimaryExpression_super() {
- super.test_parsePrimaryExpression_super();
- }
-
- @failingTest
- void test_parsePrimaryExpression_this() {
- super.test_parsePrimaryExpression_this();
- }
-
- @failingTest
- void test_parseRedirectingConstructorInvocation_named() {
- super.test_parseRedirectingConstructorInvocation_named();
- }
-
- @failingTest
- void test_parseRedirectingConstructorInvocation_unnamed() {
- super.test_parseRedirectingConstructorInvocation_unnamed();
- }
-
- @failingTest
- void test_parseRelationalExpression_as_functionType_noReturnType() {
- super.test_parseRelationalExpression_as_functionType_noReturnType();
- }
-
- @failingTest
- void test_parseRelationalExpression_as_functionType_returnType() {
- super.test_parseRelationalExpression_as_functionType_returnType();
- }
-
- @failingTest
- void test_parseRelationalExpression_as_generic() {
- super.test_parseRelationalExpression_as_generic();
- }
-
- @failingTest
- void test_parseRelationalExpression_as_simple() {
- super.test_parseRelationalExpression_as_simple();
- }
-
- @failingTest
- void test_parseRelationalExpression_as_simple_function() {
- super.test_parseRelationalExpression_as_simple_function();
- }
-
- @failingTest
- void test_parseRelationalExpression_is() {
- super.test_parseRelationalExpression_is();
- }
-
- @failingTest
- void test_parseRelationalExpression_isNot() {
- super.test_parseRelationalExpression_isNot();
- }
-
- @failingTest
- void test_parseRelationalExpression_normal() {
- super.test_parseRelationalExpression_normal();
- }
-
- @failingTest
- void test_parseRelationalExpression_super() {
- super.test_parseRelationalExpression_super();
- }
-
- @failingTest
- void test_parseShiftExpression_normal() {
- super.test_parseShiftExpression_normal();
- }
-
- @failingTest
- void test_parseShiftExpression_super() {
- super.test_parseShiftExpression_super();
- }
-
- @failingTest
- void test_parseStringLiteral_endsWithInterpolation() {
- super.test_parseStringLiteral_endsWithInterpolation();
- }
-
- @failingTest
- void test_parseStringLiteral_interpolated() {
- super.test_parseStringLiteral_interpolated();
- }
-
- @failingTest
- void test_parseStringLiteral_multiline_endsWithInterpolation() {
- super.test_parseStringLiteral_multiline_endsWithInterpolation();
- }
-
- @failingTest
- void test_parseStringLiteral_multiline_quoteAfterInterpolation() {
- super.test_parseStringLiteral_multiline_quoteAfterInterpolation();
- }
-
- @failingTest
- void test_parseStringLiteral_multiline_startsWithInterpolation() {
- super.test_parseStringLiteral_multiline_startsWithInterpolation();
- }
-
- @failingTest
- void test_parseStringLiteral_quoteAfterInterpolation() {
- super.test_parseStringLiteral_quoteAfterInterpolation();
- }
-
- @failingTest
- void test_parseStringLiteral_startsWithInterpolation() {
- super.test_parseStringLiteral_startsWithInterpolation();
- }
-
- @failingTest
- void test_parseSuperConstructorInvocation_named() {
- super.test_parseSuperConstructorInvocation_named();
- }
-
- @failingTest
- void test_parseSuperConstructorInvocation_unnamed() {
- super.test_parseSuperConstructorInvocation_unnamed();
- }
-
- @failingTest
- void test_parseUnaryExpression_decrement_normal() {
- super.test_parseUnaryExpression_decrement_normal();
- }
-
- @failingTest
- void test_parseUnaryExpression_decrement_super() {
- super.test_parseUnaryExpression_decrement_super();
- }
-
- @failingTest
- void test_parseUnaryExpression_decrement_super_propertyAccess() {
- super.test_parseUnaryExpression_decrement_super_propertyAccess();
- }
-
- @failingTest
- void test_parseUnaryExpression_decrement_super_withComment() {
- super.test_parseUnaryExpression_decrement_super_withComment();
- }
-
- @failingTest
- void test_parseUnaryExpression_increment_normal() {
- super.test_parseUnaryExpression_increment_normal();
- }
-
- @failingTest
- void test_parseUnaryExpression_increment_super_index() {
- super.test_parseUnaryExpression_increment_super_index();
- }
-
- @failingTest
- void test_parseUnaryExpression_increment_super_propertyAccess() {
- super.test_parseUnaryExpression_increment_super_propertyAccess();
- }
-
- @failingTest
- void test_parseUnaryExpression_minus_normal() {
- super.test_parseUnaryExpression_minus_normal();
- }
-
- @failingTest
- void test_parseUnaryExpression_minus_super() {
- super.test_parseUnaryExpression_minus_super();
- }
-
- @failingTest
- void test_parseUnaryExpression_not_super() {
- super.test_parseUnaryExpression_not_super();
- }
-
- @failingTest
- void test_parseUnaryExpression_tilda_normal() {
- super.test_parseUnaryExpression_tilda_normal();
- }
-
- @failingTest
- void test_parseUnaryExpression_tilda_super() {
- super.test_parseUnaryExpression_tilda_super();
- }
-}
-
-@reflectiveTest
-class FormalParameterParserTest_Forest extends FastaBodyBuilderTestCase
- with FormalParameterParserTestMixin {
- FormalParameterParserTest_Forest() : super(false);
-
- @failingTest
- void test_parseFormalParameter_covariant_final_named() {
- super.test_parseFormalParameter_covariant_final_named();
- }
-
- @failingTest
- void test_parseFormalParameter_covariant_final_normal() {
- super.test_parseFormalParameter_covariant_final_normal();
- }
-
- @failingTest
- void test_parseFormalParameter_covariant_final_positional() {
- super.test_parseFormalParameter_covariant_final_positional();
- }
-
- @failingTest
- void test_parseFormalParameter_covariant_final_type_named() {
- super.test_parseFormalParameter_covariant_final_type_named();
- }
-
- @failingTest
- void test_parseFormalParameter_covariant_final_type_normal() {
- super.test_parseFormalParameter_covariant_final_type_normal();
- }
-
- @failingTest
- void test_parseFormalParameter_covariant_final_type_positional() {
- super.test_parseFormalParameter_covariant_final_type_positional();
- }
-
- @failingTest
- void test_parseFormalParameter_covariant_type_function() {
- super.test_parseFormalParameter_covariant_type_function();
- }
-
- @failingTest
- void test_parseFormalParameter_covariant_type_named() {
- super.test_parseFormalParameter_covariant_type_named();
- }
-
- @failingTest
- void test_parseFormalParameter_covariant_type_normal() {
- super.test_parseFormalParameter_covariant_type_normal();
- }
-
- @failingTest
- void test_parseFormalParameter_covariant_type_positional() {
- super.test_parseFormalParameter_covariant_type_positional();
- }
-
- @failingTest
- void test_parseFormalParameter_covariant_var_named() {
- super.test_parseFormalParameter_covariant_var_named();
- }
-
- @failingTest
- void test_parseFormalParameter_covariant_var_normal() {
- super.test_parseFormalParameter_covariant_var_normal();
- }
-
- @failingTest
- void test_parseFormalParameter_covariant_var_positional() {
- super.test_parseFormalParameter_covariant_var_positional();
- }
-
- @failingTest
- void test_parseFormalParameter_final_named() {
- super.test_parseFormalParameter_final_named();
- }
-
- @failingTest
- void test_parseFormalParameter_final_normal() {
- super.test_parseFormalParameter_final_normal();
- }
-
- @failingTest
- void test_parseFormalParameter_final_positional() {
- super.test_parseFormalParameter_final_positional();
- }
-
- @failingTest
- void test_parseFormalParameter_final_type_named() {
- super.test_parseFormalParameter_final_type_named();
- }
-
- @failingTest
- void test_parseFormalParameter_final_type_normal() {
- super.test_parseFormalParameter_final_type_normal();
- }
-
- @failingTest
- void test_parseFormalParameter_final_type_positional() {
- super.test_parseFormalParameter_final_type_positional();
- }
-
- @failingTest
- void test_parseFormalParameter_type_function() {
- super.test_parseFormalParameter_type_function();
- }
-
- @failingTest
- void test_parseFormalParameter_type_named() {
- super.test_parseFormalParameter_type_named();
- }
-
- @failingTest
- void test_parseFormalParameter_type_named_noDefault() {
- super.test_parseFormalParameter_type_named_noDefault();
- }
-
- @failingTest
- void test_parseFormalParameter_type_normal() {
- super.test_parseFormalParameter_type_normal();
- }
-
- @failingTest
- void test_parseFormalParameter_type_positional() {
- super.test_parseFormalParameter_type_positional();
- }
-
- @failingTest
- void test_parseFormalParameter_type_positional_noDefault() {
- super.test_parseFormalParameter_type_positional_noDefault();
- }
-
- @failingTest
- void test_parseFormalParameter_var_named() {
- super.test_parseFormalParameter_var_named();
- }
-
- @failingTest
- void test_parseFormalParameter_var_normal() {
- super.test_parseFormalParameter_var_normal();
- }
-
- @failingTest
- void test_parseFormalParameter_var_positional() {
- super.test_parseFormalParameter_var_positional();
- }
-
- @failingTest
- void test_parseFormalParameterList_empty() {
- super.test_parseFormalParameterList_empty();
- }
-
- @failingTest
- void test_parseFormalParameterList_named_multiple() {
- super.test_parseFormalParameterList_named_multiple();
- }
-
- @failingTest
- void test_parseFormalParameterList_named_single() {
- super.test_parseFormalParameterList_named_single();
- }
-
- @failingTest
- void test_parseFormalParameterList_named_trailing_comma() {
- super.test_parseFormalParameterList_named_trailing_comma();
- }
-
- @failingTest
- void test_parseFormalParameterList_normal_multiple() {
- super.test_parseFormalParameterList_normal_multiple();
- }
-
- @failingTest
- void test_parseFormalParameterList_normal_named() {
- super.test_parseFormalParameterList_normal_named();
- }
-
- @failingTest
- void test_parseFormalParameterList_normal_named_inFunctionType() {
- super.test_parseFormalParameterList_normal_named_inFunctionType();
- }
-
- @failingTest
- void test_parseFormalParameterList_normal_positional() {
- super.test_parseFormalParameterList_normal_positional();
- }
-
- @failingTest
- void test_parseFormalParameterList_normal_single() {
- super.test_parseFormalParameterList_normal_single();
- }
-
- @failingTest
- void test_parseFormalParameterList_normal_single_Function() {
- super.test_parseFormalParameterList_normal_single_Function();
- }
-
- @failingTest
- void test_parseFormalParameterList_normal_single_trailing_comma() {
- super.test_parseFormalParameterList_normal_single_trailing_comma();
- }
-
- @failingTest
- void test_parseFormalParameterList_positional_multiple() {
- super.test_parseFormalParameterList_positional_multiple();
- }
-
- @failingTest
- void test_parseFormalParameterList_positional_single() {
- super.test_parseFormalParameterList_positional_single();
- }
-
- @failingTest
- void test_parseFormalParameterList_positional_trailing_comma() {
- super.test_parseFormalParameterList_positional_trailing_comma();
- }
-
- @failingTest
- void test_parseFormalParameterList_prefixedType() {
- super.test_parseFormalParameterList_prefixedType();
- }
-
- @failingTest
- void test_parseFormalParameterList_prefixedType_missingName() {
- super.test_parseFormalParameterList_prefixedType_missingName();
- }
-
- @failingTest
- void test_parseFormalParameterList_prefixedType_partial() {
- super.test_parseFormalParameterList_prefixedType_partial();
- }
-
- @failingTest
- void test_parseFormalParameterList_prefixedType_partial2() {
- super.test_parseFormalParameterList_prefixedType_partial2();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_field_const_noType() {
- super.test_parseNormalFormalParameter_field_const_noType();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_field_const_type() {
- super.test_parseNormalFormalParameter_field_const_type();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_field_final_noType() {
- super.test_parseNormalFormalParameter_field_final_noType();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_field_final_type() {
- super.test_parseNormalFormalParameter_field_final_type();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_field_function_nested() {
- super.test_parseNormalFormalParameter_field_function_nested();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_field_function_noNested() {
- super.test_parseNormalFormalParameter_field_function_noNested();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_field_function_withDocComment() {
- super.test_parseNormalFormalParameter_field_function_withDocComment();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_field_noType() {
- super.test_parseNormalFormalParameter_field_noType();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_field_type() {
- super.test_parseNormalFormalParameter_field_type();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_field_var() {
- super.test_parseNormalFormalParameter_field_var();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_field_withDocComment() {
- super.test_parseNormalFormalParameter_field_withDocComment();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_function_named() {
- super.test_parseNormalFormalParameter_function_named();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_function_noType() {
- super.test_parseNormalFormalParameter_function_noType();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_function_noType_covariant() {
- super.test_parseNormalFormalParameter_function_noType_covariant();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_function_noType_typeParameterComments() {
- super
- .test_parseNormalFormalParameter_function_noType_typeParameterComments();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_function_noType_typeParameters() {
- super.test_parseNormalFormalParameter_function_noType_typeParameters();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_function_type() {
- super.test_parseNormalFormalParameter_function_type();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_function_type_typeParameterComments() {
- super.test_parseNormalFormalParameter_function_type_typeParameterComments();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_function_type_typeParameters() {
- super.test_parseNormalFormalParameter_function_type_typeParameters();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_function_typeVoid_covariant() {
- super.test_parseNormalFormalParameter_function_typeVoid_covariant();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_function_void() {
- super.test_parseNormalFormalParameter_function_void();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_function_void_typeParameterComments() {
- super.test_parseNormalFormalParameter_function_void_typeParameterComments();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_function_void_typeParameters() {
- super.test_parseNormalFormalParameter_function_void_typeParameters();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_function_withDocComment() {
- super.test_parseNormalFormalParameter_function_withDocComment();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_simple_const_noType() {
- super.test_parseNormalFormalParameter_simple_const_noType();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_simple_const_type() {
- super.test_parseNormalFormalParameter_simple_const_type();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_simple_final_noType() {
- super.test_parseNormalFormalParameter_simple_final_noType();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_simple_final_type() {
- super.test_parseNormalFormalParameter_simple_final_type();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_simple_noName() {
- super.test_parseNormalFormalParameter_simple_noName();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_simple_noType() {
- super.test_parseNormalFormalParameter_simple_noType();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_simple_noType_namedCovariant() {
- super.test_parseNormalFormalParameter_simple_noType_namedCovariant();
- }
-
- @failingTest
- void test_parseNormalFormalParameter_simple_type() {
- super.test_parseNormalFormalParameter_simple_type();
- }
-}
-
-@reflectiveTest
-class RecoveryParserTest_Forest extends FastaBodyBuilderTestCase
- with RecoveryParserTestMixin {
- RecoveryParserTest_Forest() : super(false);
-
- @failingTest
- void test_additiveExpression_missing_LHS() {
- super.test_additiveExpression_missing_LHS();
- }
-
- @failingTest
- void test_additiveExpression_missing_LHS_RHS() {
- super.test_additiveExpression_missing_LHS_RHS();
- }
-
- @failingTest
- void test_additiveExpression_missing_RHS() {
- super.test_additiveExpression_missing_RHS();
- }
-
- @failingTest
- void test_additiveExpression_missing_RHS_super() {
- super.test_additiveExpression_missing_RHS_super();
- }
-
- @failingTest
- void test_additiveExpression_precedence_multiplicative_left() {
- super.test_additiveExpression_precedence_multiplicative_left();
- }
-
- @failingTest
- void test_additiveExpression_precedence_multiplicative_right() {
- super.test_additiveExpression_precedence_multiplicative_right();
- }
-
- @failingTest
- void test_additiveExpression_super() {
- super.test_additiveExpression_super();
- }
-
- @failingTest
- void test_assignableSelector() {
- super.test_assignableSelector();
- }
-
- @failingTest
- void test_assignmentExpression_missing_compound1() {
- super.test_assignmentExpression_missing_compound1();
- dart2Failure();
- }
-
- @failingTest
- void test_assignmentExpression_missing_compound2() {
- super.test_assignmentExpression_missing_compound2();
- dart2Failure();
- }
-
- @failingTest
- void test_assignmentExpression_missing_compound3() {
- super.test_assignmentExpression_missing_compound3();
- dart2Failure();
- }
-
- @failingTest
- void test_assignmentExpression_missing_LHS() {
- super.test_assignmentExpression_missing_LHS();
- dart2Failure();
- }
-
- @failingTest
- void test_assignmentExpression_missing_RHS() {
- super.test_assignmentExpression_missing_RHS();
- dart2Failure();
- }
-
- @failingTest
- void test_bitwiseAndExpression_missing_LHS() {
- super.test_bitwiseAndExpression_missing_LHS();
- }
-
- @failingTest
- void test_bitwiseAndExpression_missing_LHS_RHS() {
- super.test_bitwiseAndExpression_missing_LHS_RHS();
- }
-
- @failingTest
- void test_bitwiseAndExpression_missing_RHS() {
- super.test_bitwiseAndExpression_missing_RHS();
- }
-
- @failingTest
- void test_bitwiseAndExpression_missing_RHS_super() {
- super.test_bitwiseAndExpression_missing_RHS_super();
- }
-
- @failingTest
- void test_bitwiseAndExpression_precedence_equality_left() {
- super.test_bitwiseAndExpression_precedence_equality_left();
- }
-
- @failingTest
- void test_bitwiseAndExpression_precedence_equality_right() {
- super.test_bitwiseAndExpression_precedence_equality_right();
- }
-
- @failingTest
- void test_bitwiseAndExpression_super() {
- super.test_bitwiseAndExpression_super();
- }
-
- @failingTest
- void test_bitwiseOrExpression_missing_LHS() {
- super.test_bitwiseOrExpression_missing_LHS();
- }
-
- @failingTest
- void test_bitwiseOrExpression_missing_LHS_RHS() {
- super.test_bitwiseOrExpression_missing_LHS_RHS();
- }
-
- @failingTest
- void test_bitwiseOrExpression_missing_RHS() {
- super.test_bitwiseOrExpression_missing_RHS();
- }
-
- @failingTest
- void test_bitwiseOrExpression_missing_RHS_super() {
- super.test_bitwiseOrExpression_missing_RHS_super();
- }
-
- @failingTest
- void test_bitwiseOrExpression_precedence_xor_left() {
- super.test_bitwiseOrExpression_precedence_xor_left();
- }
-
- @failingTest
- void test_bitwiseOrExpression_precedence_xor_right() {
- super.test_bitwiseOrExpression_precedence_xor_right();
- }
-
- @failingTest
- void test_bitwiseOrExpression_super() {
- super.test_bitwiseOrExpression_super();
- }
-
- @failingTest
- void test_bitwiseXorExpression_missing_LHS() {
- super.test_bitwiseXorExpression_missing_LHS();
- }
-
- @failingTest
- void test_bitwiseXorExpression_missing_LHS_RHS() {
- super.test_bitwiseXorExpression_missing_LHS_RHS();
- }
-
- @failingTest
- void test_bitwiseXorExpression_missing_RHS() {
- super.test_bitwiseXorExpression_missing_RHS();
- }
-
- @failingTest
- void test_bitwiseXorExpression_missing_RHS_super() {
- super.test_bitwiseXorExpression_missing_RHS_super();
- }
-
- @failingTest
- void test_bitwiseXorExpression_precedence_and_left() {
- super.test_bitwiseXorExpression_precedence_and_left();
- }
-
- @failingTest
- void test_bitwiseXorExpression_precedence_and_right() {
- super.test_bitwiseXorExpression_precedence_and_right();
- }
-
- @failingTest
- void test_bitwiseXorExpression_super() {
- super.test_bitwiseXorExpression_super();
- }
-
- @failingTest
- void test_classTypeAlias_withBody() {
- super.test_classTypeAlias_withBody();
- }
-
- @failingTest
- void test_combinator_badIdentifier() {
- super.test_combinator_badIdentifier();
- }
-
- @failingTest
- void test_combinator_missingIdentifier() {
- super.test_combinator_missingIdentifier();
- }
-
- @failingTest
- void test_conditionalExpression_missingElse() {
- super.test_conditionalExpression_missingElse();
- dart2Failure();
- }
-
- @failingTest
- void test_conditionalExpression_missingThen() {
- super.test_conditionalExpression_missingThen();
- dart2Failure();
- }
-
- @failingTest
- void test_declarationBeforeDirective() {
- super.test_declarationBeforeDirective();
- }
-
- @failingTest
- void test_equalityExpression_missing_LHS() {
- super.test_equalityExpression_missing_LHS();
- }
-
- @failingTest
- void test_equalityExpression_missing_LHS_RHS() {
- super.test_equalityExpression_missing_LHS_RHS();
- }
-
- @failingTest
- void test_equalityExpression_missing_RHS() {
- super.test_equalityExpression_missing_RHS();
- }
-
- @failingTest
- void test_equalityExpression_missing_RHS_super() {
- super.test_equalityExpression_missing_RHS_super();
- }
-
- @failingTest
- void test_equalityExpression_precedence_relational_left() {
- super.test_equalityExpression_precedence_relational_left();
- }
-
- @failingTest
- void test_equalityExpression_precedence_relational_right() {
- super.test_equalityExpression_precedence_relational_right();
- }
-
- @failingTest
- void test_equalityExpression_super() {
- super.test_equalityExpression_super();
- }
-
- @failingTest
- void test_expressionList_multiple_end() {
- super.test_expressionList_multiple_end();
- }
-
- @failingTest
- void test_expressionList_multiple_middle() {
- super.test_expressionList_multiple_middle();
- }
-
- @failingTest
- void test_expressionList_multiple_start() {
- super.test_expressionList_multiple_start();
- }
-
- @failingTest
- void test_functionExpression_in_ConstructorFieldInitializer() {
- super.test_functionExpression_in_ConstructorFieldInitializer();
- }
-
- @failingTest
- void test_functionExpression_named() {
- super.test_functionExpression_named();
- }
-
- @failingTest
- void test_ifStatement_noElse_statement() {
- super.test_ifStatement_noElse_statement();
- }
-
- @failingTest
- void test_importDirectivePartial_as() {
- super.test_importDirectivePartial_as();
- }
-
- @failingTest
- void test_importDirectivePartial_hide() {
- super.test_importDirectivePartial_hide();
- }
-
- @failingTest
- void test_importDirectivePartial_show() {
- super.test_importDirectivePartial_show();
- }
-
- @failingTest
- void test_incomplete_conditionalExpression() {
- super.test_incomplete_conditionalExpression();
- dart2Failure();
- }
-
- @failingTest
- void test_incomplete_constructorInitializers_empty() {
- super.test_incomplete_constructorInitializers_empty();
- }
-
- @failingTest
- void test_incomplete_constructorInitializers_missingEquals() {
- super.test_incomplete_constructorInitializers_missingEquals();
- }
-
- @failingTest
- void test_incomplete_constructorInitializers_this() {
- super.test_incomplete_constructorInitializers_this();
- }
-
- @failingTest
- void test_incomplete_constructorInitializers_thisField() {
- super.test_incomplete_constructorInitializers_thisField();
- }
-
- @failingTest
- void test_incomplete_constructorInitializers_thisPeriod() {
- super.test_incomplete_constructorInitializers_thisPeriod();
- }
-
- @failingTest
- void test_incomplete_constructorInitializers_variable() {
- super.test_incomplete_constructorInitializers_variable();
- }
-
- @failingTest
- void test_incomplete_functionExpression() {
- super.test_incomplete_functionExpression();
- }
-
- @failingTest
- void test_incomplete_functionExpression2() {
- super.test_incomplete_functionExpression2();
- }
-
- @failingTest
- void test_incomplete_returnType() {
- super.test_incomplete_returnType();
- }
-
- @failingTest
- void test_incomplete_topLevelFunction() {
- super.test_incomplete_topLevelFunction();
- }
-
- @failingTest
- void test_incomplete_topLevelVariable() {
- super.test_incomplete_topLevelVariable();
- }
-
- @failingTest
- void test_incomplete_topLevelVariable_const() {
- super.test_incomplete_topLevelVariable_const();
- }
-
- @failingTest
- void test_incomplete_topLevelVariable_final() {
- super.test_incomplete_topLevelVariable_final();
- }
-
- @failingTest
- void test_incomplete_topLevelVariable_var() {
- super.test_incomplete_topLevelVariable_var();
- }
-
- @failingTest
- void test_incompleteField_const() {
- super.test_incompleteField_const();
- }
-
- @failingTest
- void test_incompleteField_final() {
- super.test_incompleteField_final();
- }
-
- @failingTest
- void test_incompleteField_static() {
- super.test_incompleteField_static();
- }
-
- @failingTest
- void test_incompleteField_static2() {
- super.test_incompleteField_static2();
- }
-
- @failingTest
- void test_incompleteField_type() {
- super.test_incompleteField_type();
- }
-
- @failingTest
- void test_incompleteField_var() {
- super.test_incompleteField_var();
- }
-
- @failingTest
- void test_incompleteForEach() {
- super.test_incompleteForEach();
- }
-
- @failingTest
- void test_incompleteLocalVariable_atTheEndOfBlock() {
- super.test_incompleteLocalVariable_atTheEndOfBlock();
- }
-
- @failingTest
- void test_incompleteLocalVariable_atTheEndOfBlock_modifierOnly() {
- super.test_incompleteLocalVariable_atTheEndOfBlock_modifierOnly();
- }
-
- @failingTest
- void test_incompleteLocalVariable_beforeIdentifier() {
- super.test_incompleteLocalVariable_beforeIdentifier();
- }
-
- @failingTest
- void test_incompleteLocalVariable_beforeKeyword() {
- super.test_incompleteLocalVariable_beforeKeyword();
- }
-
- @failingTest
- void test_incompleteLocalVariable_beforeNextBlock() {
- super.test_incompleteLocalVariable_beforeNextBlock();
- }
-
- @failingTest
- void test_incompleteLocalVariable_parameterizedType() {
- super.test_incompleteLocalVariable_parameterizedType();
- }
-
- @failingTest
- void test_incompleteTypeArguments_field() {
- super.test_incompleteTypeArguments_field();
- }
-
- @failingTest
- void test_incompleteTypeParameters() {
- super.test_incompleteTypeParameters();
- }
-
- @failingTest
- void test_incompleteTypeParameters2() {
- super.test_incompleteTypeParameters2();
- }
-
- @failingTest
- void test_incompleteTypeParameters3() {
- super.test_incompleteTypeParameters3();
- }
-
- @failingTest
- void test_invalidFunctionBodyModifier() {
- super.test_invalidFunctionBodyModifier();
- }
-
- @failingTest
- void test_invalidTypeParameters() {
- super.test_invalidTypeParameters();
- }
-
- @failingTest
- void test_isExpression_noType() {
- super.test_isExpression_noType();
- }
-
- @failingTest
- void test_keywordInPlaceOfIdentifier() {
- super.test_keywordInPlaceOfIdentifier();
- }
-
- @failingTest
- void test_logicalAndExpression_missing_LHS() {
- super.test_logicalAndExpression_missing_LHS();
- dart2Failure();
- }
-
- @failingTest
- void test_logicalAndExpression_missing_LHS_RHS() {
- super.test_logicalAndExpression_missing_LHS_RHS();
- dart2Failure();
- }
-
- @failingTest
- void test_logicalAndExpression_missing_RHS() {
- super.test_logicalAndExpression_missing_RHS();
- dart2Failure();
- }
-
- @failingTest
- void test_logicalAndExpression_precedence_bitwiseOr_left() {
- super.test_logicalAndExpression_precedence_bitwiseOr_left();
- }
-
- @failingTest
- void test_logicalAndExpression_precedence_bitwiseOr_right() {
- super.test_logicalAndExpression_precedence_bitwiseOr_right();
- }
-
- @failingTest
- void test_logicalOrExpression_missing_LHS() {
- super.test_logicalOrExpression_missing_LHS();
- dart2Failure();
- }
-
- @failingTest
- void test_logicalOrExpression_missing_LHS_RHS() {
- super.test_logicalOrExpression_missing_LHS_RHS();
- dart2Failure();
- }
-
- @failingTest
- void test_logicalOrExpression_missing_RHS() {
- super.test_logicalOrExpression_missing_RHS();
- dart2Failure();
- }
-
- @failingTest
- void test_logicalOrExpression_precedence_logicalAnd_left() {
- super.test_logicalOrExpression_precedence_logicalAnd_left();
- dart2Failure();
- }
-
- @failingTest
- void test_logicalOrExpression_precedence_logicalAnd_right() {
- super.test_logicalOrExpression_precedence_logicalAnd_right();
- dart2Failure();
- }
-
- @failingTest
- void test_method_missingBody() {
- super.test_method_missingBody();
- }
-
- @failingTest
- void test_missing_commaInArgumentList() {
- super.test_missing_commaInArgumentList();
- }
-
- @failingTest
- void test_missingComma_beforeNamedArgument() {
- super.test_missingComma_beforeNamedArgument();
- }
-
- @failingTest
- void test_missingGet() {
- super.test_missingGet();
- }
-
- @failingTest
- void test_missingIdentifier_afterAnnotation() {
- super.test_missingIdentifier_afterAnnotation();
- }
-
- @failingTest
- void test_missingSemicolon_varialeDeclarationList() {
- super.test_missingSemicolon_varialeDeclarationList();
- }
-
- @failingTest
- void test_multiplicativeExpression_missing_LHS() {
- super.test_multiplicativeExpression_missing_LHS();
- }
-
- @failingTest
- void test_multiplicativeExpression_missing_LHS_RHS() {
- super.test_multiplicativeExpression_missing_LHS_RHS();
- }
-
- @failingTest
- void test_multiplicativeExpression_missing_RHS() {
- super.test_multiplicativeExpression_missing_RHS();
- }
-
- @failingTest
- void test_multiplicativeExpression_missing_RHS_super() {
- super.test_multiplicativeExpression_missing_RHS_super();
- }
-
- @failingTest
- void test_multiplicativeExpression_precedence_unary_left() {
- super.test_multiplicativeExpression_precedence_unary_left();
- }
-
- @failingTest
- void test_multiplicativeExpression_precedence_unary_right() {
- super.test_multiplicativeExpression_precedence_unary_right();
- }
-
- @failingTest
- void test_multiplicativeExpression_super() {
- super.test_multiplicativeExpression_super();
- }
-
- @failingTest
- void test_namedParameterOutsideGroup() {
- super.test_namedParameterOutsideGroup();
- }
-
- @failingTest
- void test_nonStringLiteralUri_import() {
- super.test_nonStringLiteralUri_import();
- }
-
- @failingTest
- void test_prefixExpression_missing_operand_minus() {
- super.test_prefixExpression_missing_operand_minus();
- }
-
- @failingTest
- void test_primaryExpression_argumentDefinitionTest() {
- super.test_primaryExpression_argumentDefinitionTest();
- }
-
- @failingTest
- void test_propertyAccess_missing_LHS_RHS() {
- super.test_propertyAccess_missing_LHS_RHS();
- }
-
- @failingTest
- void test_relationalExpression_missing_LHS() {
- super.test_relationalExpression_missing_LHS();
- }
-
- @failingTest
- void test_relationalExpression_missing_LHS_RHS() {
- super.test_relationalExpression_missing_LHS_RHS();
- }
-
- @failingTest
- void test_relationalExpression_missing_RHS() {
- super.test_relationalExpression_missing_RHS();
- }
-
- @failingTest
- void test_relationalExpression_precedence_shift_right() {
- super.test_relationalExpression_precedence_shift_right();
- }
-
- @failingTest
- void test_shiftExpression_missing_LHS() {
- super.test_shiftExpression_missing_LHS();
- }
-
- @failingTest
- void test_shiftExpression_missing_LHS_RHS() {
- super.test_shiftExpression_missing_LHS_RHS();
- }
-
- @failingTest
- void test_shiftExpression_missing_RHS() {
- super.test_shiftExpression_missing_RHS();
- }
-
- @failingTest
- void test_shiftExpression_missing_RHS_super() {
- super.test_shiftExpression_missing_RHS_super();
- }
-
- @failingTest
- void test_shiftExpression_precedence_unary_left() {
- super.test_shiftExpression_precedence_unary_left();
- }
-
- @failingTest
- void test_shiftExpression_precedence_unary_right() {
- super.test_shiftExpression_precedence_unary_right();
- }
-
- @failingTest
- void test_shiftExpression_super() {
- super.test_shiftExpression_super();
- }
-
- @failingTest
- void test_typedef_eof() {
- super.test_typedef_eof();
- }
-
- @failingTest
- void test_unaryPlus() {
- super.test_unaryPlus();
- }
-}
-
-@reflectiveTest
-class SimpleParserTest_Forest extends FastaBodyBuilderTestCase
- with SimpleParserTestMixin {
- SimpleParserTest_Forest() : super(false);
-
- @failingTest
- void test_classDeclaration_complexTypeParam() {
- super.test_classDeclaration_complexTypeParam();
- }
-
- @failingTest
- void test_parseAnnotation_n1() {
- super.test_parseAnnotation_n1();
- }
-
- @failingTest
- void test_parseAnnotation_n1_a() {
- super.test_parseAnnotation_n1_a();
- }
-
- @failingTest
- void test_parseAnnotation_n2() {
- super.test_parseAnnotation_n2();
- }
-
- @failingTest
- void test_parseAnnotation_n2_a() {
- super.test_parseAnnotation_n2_a();
- }
-
- @failingTest
- void test_parseAnnotation_n3() {
- super.test_parseAnnotation_n3();
- }
-
- @failingTest
- void test_parseAnnotation_n3_a() {
- super.test_parseAnnotation_n3_a();
- }
-
- @failingTest
- void test_parseArgumentList_empty() {
- super.test_parseArgumentList_empty();
- }
-
- @failingTest
- void test_parseArgumentList_mixed() {
- super.test_parseArgumentList_mixed();
- }
-
- @failingTest
- void test_parseArgumentList_noNamed() {
- super.test_parseArgumentList_noNamed();
- }
-
- @failingTest
- void test_parseArgumentList_onlyNamed() {
- super.test_parseArgumentList_onlyNamed();
- }
-
- @failingTest
- void test_parseArgumentList_trailing_comma() {
- super.test_parseArgumentList_trailing_comma();
- }
-
- @failingTest
- void test_parseArgumentList_typeArguments() {
- super.test_parseArgumentList_typeArguments();
- }
-
- @failingTest
- void test_parseArgumentList_typeArguments_none() {
- super.test_parseArgumentList_typeArguments_none();
- }
-
- @failingTest
- void test_parseArgumentList_typeArguments_prefixed() {
- super.test_parseArgumentList_typeArguments_prefixed();
- }
-
- @failingTest
- void test_parseCombinators_h() {
- super.test_parseCombinators_h();
- }
-
- @failingTest
- void test_parseCombinators_hs() {
- super.test_parseCombinators_hs();
- }
-
- @failingTest
- void test_parseCombinators_hshs() {
- super.test_parseCombinators_hshs();
- }
-
- @failingTest
- void test_parseCombinators_s() {
- super.test_parseCombinators_s();
- }
-
- @failingTest
- void test_parseCommentAndMetadata_c() {
- super.test_parseCommentAndMetadata_c();
- }
-
- @failingTest
- void test_parseCommentAndMetadata_cmc() {
- super.test_parseCommentAndMetadata_cmc();
- }
-
- @failingTest
- void test_parseCommentAndMetadata_cmcm() {
- super.test_parseCommentAndMetadata_cmcm();
- }
-
- @failingTest
- void test_parseCommentAndMetadata_cmm() {
- super.test_parseCommentAndMetadata_cmm();
- }
-
- @failingTest
- void test_parseCommentAndMetadata_m() {
- super.test_parseCommentAndMetadata_m();
- }
-
- @failingTest
- void test_parseCommentAndMetadata_mcm() {
- super.test_parseCommentAndMetadata_mcm();
- }
-
- @failingTest
- void test_parseCommentAndMetadata_mcmc() {
- super.test_parseCommentAndMetadata_mcmc();
- }
-
- @failingTest
- void test_parseCommentAndMetadata_mm() {
- super.test_parseCommentAndMetadata_mm();
- }
-
- @failingTest
- void test_parseCommentAndMetadata_none() {
- super.test_parseCommentAndMetadata_none();
- }
-
- @failingTest
- void test_parseCommentAndMetadata_singleLine() {
- super.test_parseCommentAndMetadata_singleLine();
- }
-
- @failingTest
- void test_parseConfiguration_noOperator_dottedIdentifier() {
- super.test_parseConfiguration_noOperator_dottedIdentifier();
- }
-
- @failingTest
- void test_parseConfiguration_noOperator_simpleIdentifier() {
- super.test_parseConfiguration_noOperator_simpleIdentifier();
- }
-
- @failingTest
- void test_parseConfiguration_operator_dottedIdentifier() {
- super.test_parseConfiguration_operator_dottedIdentifier();
- }
-
- @failingTest
- void test_parseConfiguration_operator_simpleIdentifier() {
- super.test_parseConfiguration_operator_simpleIdentifier();
- }
-
- @failingTest
- void test_parseConstructorName_named_noPrefix() {
- super.test_parseConstructorName_named_noPrefix();
- }
-
- @failingTest
- void test_parseConstructorName_named_prefixed() {
- super.test_parseConstructorName_named_prefixed();
- }
-
- @failingTest
- void test_parseConstructorName_unnamed_noPrefix() {
- super.test_parseConstructorName_unnamed_noPrefix();
- }
-
- @failingTest
- void test_parseConstructorName_unnamed_prefixed() {
- super.test_parseConstructorName_unnamed_prefixed();
- }
-
- @failingTest
- void test_parseDocumentationComment_block() {
- super.test_parseDocumentationComment_block();
- }
-
- @failingTest
- void test_parseDocumentationComment_block_withReference() {
- super.test_parseDocumentationComment_block_withReference();
- }
-
- @failingTest
- void test_parseDocumentationComment_endOfLine() {
- super.test_parseDocumentationComment_endOfLine();
- }
-
- @failingTest
- void test_parseExtendsClause() {
- super.test_parseExtendsClause();
- }
-
- @failingTest
- void test_parseFunctionBody_block() {
- super.test_parseFunctionBody_block();
- }
-
- @failingTest
- void test_parseFunctionBody_block_async() {
- super.test_parseFunctionBody_block_async();
- }
-
- @failingTest
- void test_parseFunctionBody_block_asyncGenerator() {
- super.test_parseFunctionBody_block_asyncGenerator();
- }
-
- @failingTest
- void test_parseFunctionBody_block_syncGenerator() {
- super.test_parseFunctionBody_block_syncGenerator();
- }
-
- @failingTest
- void test_parseFunctionBody_empty() {
- super.test_parseFunctionBody_empty();
- }
-
- @failingTest
- void test_parseFunctionBody_expression() {
- super.test_parseFunctionBody_expression();
- }
-
- @failingTest
- void test_parseFunctionBody_expression_async() {
- super.test_parseFunctionBody_expression_async();
- }
-
- @failingTest
- void test_parseIdentifierList_multiple() {
- super.test_parseIdentifierList_multiple();
- }
-
- @failingTest
- void test_parseIdentifierList_single() {
- super.test_parseIdentifierList_single();
- }
-
- @failingTest
- void test_parseImplementsClause_multiple() {
- super.test_parseImplementsClause_multiple();
- }
-
- @failingTest
- void test_parseImplementsClause_single() {
- super.test_parseImplementsClause_single();
- }
-
- @failingTest
- void test_parseInstanceCreation_noKeyword_noPrefix() {
- super.test_parseInstanceCreation_noKeyword_noPrefix();
- }
-
- @failingTest
- void test_parseInstanceCreation_noKeyword_prefix() {
- super.test_parseInstanceCreation_noKeyword_prefix();
- }
-
- @failingTest
- void test_parseInstanceCreation_noKeyword_varInit() {
- super.test_parseInstanceCreation_noKeyword_varInit();
- }
-
- @failingTest
- void test_parseLibraryIdentifier_builtin() {
- super.test_parseLibraryIdentifier_builtin();
- }
-
- @failingTest
- void test_parseLibraryIdentifier_invalid() {
- super.test_parseLibraryIdentifier_invalid();
- }
-
- @failingTest
- void test_parseLibraryIdentifier_multiple() {
- super.test_parseLibraryIdentifier_multiple();
- }
-
- @failingTest
- void test_parseLibraryIdentifier_pseudo() {
- super.test_parseLibraryIdentifier_pseudo();
- }
-
- @failingTest
- void test_parseLibraryIdentifier_single() {
- super.test_parseLibraryIdentifier_single();
- }
-
- @failingTest
- void test_parseStatement_function_noReturnType() {
- super.test_parseStatement_function_noReturnType();
- }
-
- @failingTest
- void test_parseTypeAnnotation_function_noReturnType_noParameters() {
- super.test_parseTypeAnnotation_function_noReturnType_noParameters();
- }
-
- @failingTest
- void test_parseTypeAnnotation_function_noReturnType_parameters() {
- super.test_parseTypeAnnotation_function_noReturnType_parameters();
- }
-
- @failingTest
- void test_parseTypeAnnotation_function_noReturnType_typeParameters() {
- super.test_parseTypeAnnotation_function_noReturnType_typeParameters();
- }
-
- @failingTest
- void
- test_parseTypeAnnotation_function_noReturnType_typeParameters_parameters() {
- super
- .test_parseTypeAnnotation_function_noReturnType_typeParameters_parameters();
- }
-
- @failingTest
- void test_parseTypeAnnotation_function_returnType_classFunction() {
- super.test_parseTypeAnnotation_function_returnType_classFunction();
- }
-
- @failingTest
- void test_parseTypeAnnotation_function_returnType_function() {
- super.test_parseTypeAnnotation_function_returnType_function();
- }
-
- @failingTest
- void test_parseTypeAnnotation_function_returnType_noParameters() {
- super.test_parseTypeAnnotation_function_returnType_noParameters();
- }
-
- @failingTest
- void test_parseTypeAnnotation_function_returnType_parameters() {
- super.test_parseTypeAnnotation_function_returnType_parameters();
- }
-
- @failingTest
- void test_parseTypeAnnotation_function_returnType_simple() {
- super.test_parseTypeAnnotation_function_returnType_simple();
- }
-
- @failingTest
- void test_parseTypeAnnotation_function_returnType_typeParameters() {
- super.test_parseTypeAnnotation_function_returnType_typeParameters();
- }
-
- @failingTest
- void
- test_parseTypeAnnotation_function_returnType_typeParameters_parameters() {
- super
- .test_parseTypeAnnotation_function_returnType_typeParameters_parameters();
- }
-
- @failingTest
- void test_parseTypeAnnotation_function_returnType_withArguments() {
- super.test_parseTypeAnnotation_function_returnType_withArguments();
- }
-
- @failingTest
- void test_parseTypeAnnotation_named() {
- super.test_parseTypeAnnotation_named();
- }
-
- @failingTest
- void test_parseTypeArgumentList_empty() {
- super.test_parseTypeArgumentList_empty();
- }
-
- @failingTest
- void test_parseTypeArgumentList_multiple() {
- super.test_parseTypeArgumentList_multiple();
- }
-
- @failingTest
- void test_parseTypeArgumentList_nested() {
- super.test_parseTypeArgumentList_nested();
- }
-
- @failingTest
- void test_parseTypeArgumentList_nested_withComment_double() {
- super.test_parseTypeArgumentList_nested_withComment_double();
- }
-
- @failingTest
- void test_parseTypeArgumentList_nested_withComment_tripple() {
- super.test_parseTypeArgumentList_nested_withComment_tripple();
- }
-
- @failingTest
- void test_parseTypeArgumentList_single() {
- super.test_parseTypeArgumentList_single();
- }
-
- @failingTest
- void test_parseTypeName_parameterized() {
- super.test_parseTypeName_parameterized();
- }
-
- @failingTest
- void test_parseTypeName_simple() {
- super.test_parseTypeName_simple();
- }
-
- @failingTest
- void test_parseTypeParameter_bounded_functionType_noReturn() {
- super.test_parseTypeParameter_bounded_functionType_noReturn();
- }
-
- @failingTest
- void test_parseTypeParameter_bounded_functionType_return() {
- super.test_parseTypeParameter_bounded_functionType_return();
- }
-
- @failingTest
- void test_parseTypeParameter_bounded_generic() {
- super.test_parseTypeParameter_bounded_generic();
- }
-
- @failingTest
- void test_parseTypeParameter_bounded_simple() {
- super.test_parseTypeParameter_bounded_simple();
- }
-
- @failingTest
- void test_parseTypeParameter_simple() {
- super.test_parseTypeParameter_simple();
- }
-
- @failingTest
- void test_parseTypeParameterList_multiple() {
- super.test_parseTypeParameterList_multiple();
- }
-
- @failingTest
- void test_parseTypeParameterList_parameterizedWithTrailingEquals() {
- super.test_parseTypeParameterList_parameterizedWithTrailingEquals();
- }
-
- @failingTest
- void test_parseTypeParameterList_parameterizedWithTrailingEquals2() {
- super.test_parseTypeParameterList_parameterizedWithTrailingEquals2();
- }
-
- @failingTest
- void test_parseTypeParameterList_single() {
- super.test_parseTypeParameterList_single();
- }
-
- @failingTest
- void test_parseTypeParameterList_withTrailingEquals() {
- super.test_parseTypeParameterList_withTrailingEquals();
- }
-
- @failingTest
- void test_parseVariableDeclaration_equals() {
- super.test_parseVariableDeclaration_equals();
- }
-
- @failingTest
- void test_parseVariableDeclaration_noEquals() {
- super.test_parseVariableDeclaration_noEquals();
- }
-
- @failingTest
- void test_parseWithClause_multiple() {
- super.test_parseWithClause_multiple();
- }
-
- @failingTest
- void test_parseWithClause_single() {
- super.test_parseWithClause_single();
- }
-}
-
-@reflectiveTest
-class StatementParserTest_Forest extends FastaBodyBuilderTestCase
- with StatementParserTestMixin {
- StatementParserTest_Forest() : super(false);
-
- @failingTest
- void test_invalid_typeParamAnnotation() {
- super.test_invalid_typeParamAnnotation();
- }
-
- @failingTest
- void test_invalid_typeParamAnnotation2() {
- super.test_invalid_typeParamAnnotation2();
- }
-
- @failingTest
- void test_invalid_typeParamAnnotation3() {
- super.test_invalid_typeParamAnnotation3();
- }
-
- @failingTest
- void test_parseForStatement_each_await() {
- super.test_parseForStatement_each_await();
- }
-
- @failingTest
- void test_parseForStatement_each_genericFunctionType() {
- super.test_parseForStatement_each_genericFunctionType();
- }
-
- @failingTest
- void test_parseForStatement_each_identifier() {
- super.test_parseForStatement_each_identifier();
- }
-
- @failingTest
- void test_parseForStatement_each_noType_metadata() {
- super.test_parseForStatement_each_noType_metadata();
- }
-
- @failingTest
- void test_parseForStatement_each_type() {
- super.test_parseForStatement_each_type();
- }
-
- @failingTest
- void test_parseForStatement_each_var() {
- super.test_parseForStatement_each_var();
- }
-
- @failingTest
- void test_parseForStatement_loop_c() {
- super.test_parseForStatement_loop_c();
- }
-
- @failingTest
- void test_parseForStatement_loop_cu() {
- super.test_parseForStatement_loop_cu();
- }
-
- @failingTest
- void test_parseForStatement_loop_ecu() {
- super.test_parseForStatement_loop_ecu();
- }
-
- @failingTest
- void test_parseForStatement_loop_i() {
- super.test_parseForStatement_loop_i();
- }
-
- @failingTest
- void test_parseForStatement_loop_i_withMetadata() {
- super.test_parseForStatement_loop_i_withMetadata();
- }
-
- @failingTest
- void test_parseForStatement_loop_ic() {
- super.test_parseForStatement_loop_ic();
- }
-
- @failingTest
- void test_parseForStatement_loop_icu() {
- super.test_parseForStatement_loop_icu();
- }
-
- @failingTest
- void test_parseForStatement_loop_iicuu() {
- super.test_parseForStatement_loop_iicuu();
- }
-
- @failingTest
- void test_parseForStatement_loop_iu() {
- super.test_parseForStatement_loop_iu();
- }
-
- @failingTest
- void test_parseForStatement_loop_u() {
- super.test_parseForStatement_loop_u();
- }
-
- @failingTest
- void test_parseFunctionDeclarationStatement() {
- super.test_parseFunctionDeclarationStatement();
- }
-
- @failingTest
- void test_parseFunctionDeclarationStatement_typeParameterComments() {
- super.test_parseFunctionDeclarationStatement_typeParameterComments();
- }
-
- @failingTest
- void test_parseFunctionDeclarationStatement_typeParameters() {
- super.test_parseFunctionDeclarationStatement_typeParameters();
- }
-
- @failingTest
- void test_parseFunctionDeclarationStatement_typeParameters_noReturnType() {
- super.test_parseFunctionDeclarationStatement_typeParameters_noReturnType();
- }
-
- @failingTest
- void test_parseIfStatement_else_statement() {
- super.test_parseIfStatement_else_statement();
- }
-
- @failingTest
- void test_parseIfStatement_noElse_statement() {
- super.test_parseIfStatement_noElse_statement();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_const_object() {
- super.test_parseNonLabeledStatement_const_object();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_const_object_named_typeParameters() {
- super.test_parseNonLabeledStatement_const_object_named_typeParameters();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_constructorInvocation() {
- super.test_parseNonLabeledStatement_constructorInvocation();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_functionDeclaration() {
- super.test_parseNonLabeledStatement_functionDeclaration();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_functionDeclaration_arguments() {
- super.test_parseNonLabeledStatement_functionDeclaration_arguments();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_functionExpressionIndex() {
- super.test_parseNonLabeledStatement_functionExpressionIndex();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_functionInvocation() {
- super.test_parseNonLabeledStatement_functionInvocation();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_invokeFunctionExpression() {
- super.test_parseNonLabeledStatement_invokeFunctionExpression();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_localFunction_gftReturnType() {
- super.test_parseNonLabeledStatement_localFunction_gftReturnType();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_startingWithBuiltInIdentifier() {
- super.test_parseNonLabeledStatement_startingWithBuiltInIdentifier();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_typeCast() {
- super.test_parseNonLabeledStatement_typeCast();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_variableDeclaration_final_namedFunction() {
- super
- .test_parseNonLabeledStatement_variableDeclaration_final_namedFunction();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_variableDeclaration_gftType() {
- super.test_parseNonLabeledStatement_variableDeclaration_gftType();
- }
-
- @failingTest
- void
- test_parseNonLabeledStatement_variableDeclaration_gftType_functionReturnType() {
- super
- .test_parseNonLabeledStatement_variableDeclaration_gftType_functionReturnType();
- }
-
- @failingTest
- void
- test_parseNonLabeledStatement_variableDeclaration_gftType_gftReturnType() {
- super
- .test_parseNonLabeledStatement_variableDeclaration_gftType_gftReturnType();
- }
-
- @failingTest
- void
- test_parseNonLabeledStatement_variableDeclaration_gftType_gftReturnType2() {
- super
- .test_parseNonLabeledStatement_variableDeclaration_gftType_gftReturnType2();
- }
-
- @failingTest
- void
- test_parseNonLabeledStatement_variableDeclaration_gftType_noReturnType() {
- super
- .test_parseNonLabeledStatement_variableDeclaration_gftType_noReturnType();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_variableDeclaration_gftType_returnType() {
- super
- .test_parseNonLabeledStatement_variableDeclaration_gftType_returnType();
- }
-
- @failingTest
- void
- test_parseNonLabeledStatement_variableDeclaration_gftType_voidReturnType() {
- super
- .test_parseNonLabeledStatement_variableDeclaration_gftType_voidReturnType();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_variableDeclaration_typeParam() {
- super.test_parseNonLabeledStatement_variableDeclaration_typeParam();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_variableDeclaration_typeParam2() {
- super.test_parseNonLabeledStatement_variableDeclaration_typeParam2();
- }
-
- @failingTest
- void test_parseNonLabeledStatement_variableDeclaration_typeParam3() {
- super.test_parseNonLabeledStatement_variableDeclaration_typeParam3();
- }
-
- @failingTest
- void test_parseStatement_emptyTypeArgumentList() {
- super.test_parseStatement_emptyTypeArgumentList();
- }
-
- @failingTest
- void test_parseStatement_function_gftReturnType() {
- super.test_parseStatement_function_gftReturnType();
- }
-
- @failingTest
- void
- test_parseStatement_functionDeclaration_noReturnType_typeParameterComments() {
- super
- .test_parseStatement_functionDeclaration_noReturnType_typeParameterComments();
- }
-
- @failingTest
- void test_parseStatement_functionDeclaration_noReturnType_typeParameters() {
- super.test_parseStatement_functionDeclaration_noReturnType_typeParameters();
- }
-
- @failingTest
- void test_parseStatement_functionDeclaration_returnType() {
- super.test_parseStatement_functionDeclaration_returnType();
- }
-
- @failingTest
- void test_parseStatement_functionDeclaration_returnType_typeParameters() {
- super.test_parseStatement_functionDeclaration_returnType_typeParameters();
- }
-
- @failingTest
- void test_parseSwitchStatement_case() {
- super.test_parseSwitchStatement_case();
- }
-
- @failingTest
- void test_parseSwitchStatement_empty() {
- super.test_parseSwitchStatement_empty();
- }
-
- @failingTest
- void test_parseSwitchStatement_labeledCase() {
- super.test_parseSwitchStatement_labeledCase();
- }
-
- @failingTest
- void test_parseSwitchStatement_labeledDefault() {
- super.test_parseSwitchStatement_labeledDefault();
- }
-
- @failingTest
- void test_parseSwitchStatement_labeledStatementInCase() {
- super.test_parseSwitchStatement_labeledStatementInCase();
- }
-
- @failingTest
- void test_parseTryStatement_catch() {
- super.test_parseTryStatement_catch();
- }
-
- @failingTest
- void test_parseTryStatement_catch_error_missingCatchParam() {
- super.test_parseTryStatement_catch_error_missingCatchParam();
- }
-
- @failingTest
- void test_parseTryStatement_catch_error_missingCatchParen() {
- super.test_parseTryStatement_catch_error_missingCatchParen();
- }
-
- @failingTest
- void test_parseTryStatement_catch_error_missingCatchTrace() {
- super.test_parseTryStatement_catch_error_missingCatchTrace();
- }
-
- @failingTest
- void test_parseTryStatement_catch_finally() {
- super.test_parseTryStatement_catch_finally();
- }
-
- @failingTest
- void test_parseTryStatement_multiple() {
- super.test_parseTryStatement_multiple();
- }
-
- @failingTest
- void test_parseTryStatement_on() {
- super.test_parseTryStatement_on();
- }
-
- @failingTest
- void test_parseTryStatement_on_catch() {
- super.test_parseTryStatement_on_catch();
- }
-
- @failingTest
- void test_parseTryStatement_on_catch_finally() {
- super.test_parseTryStatement_on_catch_finally();
- }
-
- @failingTest
- void test_parseVariableDeclaration_equals_builtIn() {
- super.test_parseVariableDeclaration_equals_builtIn();
- }
-
- @failingTest
- void test_parseVariableDeclarationListAfterMetadata_const_noType() {
- super.test_parseVariableDeclarationListAfterMetadata_const_noType();
- }
-
- @failingTest
- void test_parseVariableDeclarationListAfterMetadata_const_type() {
- super.test_parseVariableDeclarationListAfterMetadata_const_type();
- }
-
- @failingTest
- void test_parseVariableDeclarationListAfterMetadata_const_typeComment() {
- super.test_parseVariableDeclarationListAfterMetadata_const_typeComment();
- }
-
- @failingTest
- void test_parseVariableDeclarationListAfterMetadata_dynamic_typeComment() {
- super.test_parseVariableDeclarationListAfterMetadata_dynamic_typeComment();
- }
-
- @failingTest
- void test_parseVariableDeclarationListAfterMetadata_final_noType() {
- super.test_parseVariableDeclarationListAfterMetadata_final_noType();
- }
-
- @failingTest
- void test_parseVariableDeclarationListAfterMetadata_final_type() {
- super.test_parseVariableDeclarationListAfterMetadata_final_type();
- }
-
- @failingTest
- void test_parseVariableDeclarationListAfterMetadata_final_typeComment() {
- super.test_parseVariableDeclarationListAfterMetadata_final_typeComment();
- }
-
- @failingTest
- void test_parseVariableDeclarationListAfterMetadata_type_multiple() {
- super.test_parseVariableDeclarationListAfterMetadata_type_multiple();
- }
-
- @failingTest
- void test_parseVariableDeclarationListAfterMetadata_type_single() {
- super.test_parseVariableDeclarationListAfterMetadata_type_single();
- }
-
- @failingTest
- void test_parseVariableDeclarationListAfterMetadata_type_typeComment() {
- super.test_parseVariableDeclarationListAfterMetadata_type_typeComment();
- }
-
- @failingTest
- void test_parseVariableDeclarationListAfterMetadata_var_multiple() {
- super.test_parseVariableDeclarationListAfterMetadata_var_multiple();
- }
-
- @failingTest
- void test_parseVariableDeclarationListAfterMetadata_var_single() {
- super.test_parseVariableDeclarationListAfterMetadata_var_single();
- }
-
- @failingTest
- void test_parseVariableDeclarationListAfterMetadata_var_typeComment() {
- super.test_parseVariableDeclarationListAfterMetadata_var_typeComment();
- }
-
- @failingTest
- void test_parseVariableDeclarationStatementAfterMetadata_multiple() {
- super.test_parseVariableDeclarationStatementAfterMetadata_multiple();
- }
-
- @failingTest
- void test_parseVariableDeclarationStatementAfterMetadata_single() {
- super.test_parseVariableDeclarationStatementAfterMetadata_single();
- }
-
- @failingTest
- void test_parseYieldStatement_each() {
- super.test_parseYieldStatement_each();
- }
-
- @failingTest
- void test_parseYieldStatement_normal() {
- super.test_parseYieldStatement_normal();
- }
-}
-
-@reflectiveTest
-class TopLevelParserTest_Forest extends FastaBodyBuilderTestCase
- with TopLevelParserTestMixin {
- TopLevelParserTest_Forest() : super(false);
-
- @failingTest
- void test_function_literal_allowed_at_toplevel() {
- super.test_function_literal_allowed_at_toplevel();
- }
-
- @failingTest
- void
- test_function_literal_allowed_in_ArgumentList_in_ConstructorFieldInitializer() {
- super
- .test_function_literal_allowed_in_ArgumentList_in_ConstructorFieldInitializer();
- }
-
- @failingTest
- void
- test_function_literal_allowed_in_IndexExpression_in_ConstructorFieldInitializer() {
- super
- .test_function_literal_allowed_in_IndexExpression_in_ConstructorFieldInitializer();
- }
-
- @failingTest
- void
- test_function_literal_allowed_in_ListLiteral_in_ConstructorFieldInitializer() {
- super
- .test_function_literal_allowed_in_ListLiteral_in_ConstructorFieldInitializer();
- }
-
- @failingTest
- void
- test_function_literal_allowed_in_MapLiteral_in_ConstructorFieldInitializer() {
- super
- .test_function_literal_allowed_in_MapLiteral_in_ConstructorFieldInitializer();
- }
-
- @failingTest
- void
- test_function_literal_allowed_in_ParenthesizedExpression_in_ConstructorFieldInitializer() {
- super
- .test_function_literal_allowed_in_ParenthesizedExpression_in_ConstructorFieldInitializer();
- }
-
- @failingTest
- void
- test_function_literal_allowed_in_StringInterpolation_in_ConstructorFieldInitializer() {
- super
- .test_function_literal_allowed_in_StringInterpolation_in_ConstructorFieldInitializer();
- }
-
- @failingTest
- void test_import_as_show() {
- super.test_import_as_show();
- }
-
- @failingTest
- void test_import_show_hide() {
- super.test_import_show_hide();
- }
-
- @failingTest
- void test_import_withDocComment() {
- super.test_import_withDocComment();
- }
-
- @failingTest
- void test_parseClassDeclaration_abstract() {
- super.test_parseClassDeclaration_abstract();
- }
-
- @failingTest
- void test_parseClassDeclaration_empty() {
- super.test_parseClassDeclaration_empty();
- }
-
- @failingTest
- void test_parseClassDeclaration_extends() {
- super.test_parseClassDeclaration_extends();
- }
-
- @failingTest
- void test_parseClassDeclaration_extendsAndImplements() {
- super.test_parseClassDeclaration_extendsAndImplements();
- }
-
- @failingTest
- void test_parseClassDeclaration_extendsAndWith() {
- super.test_parseClassDeclaration_extendsAndWith();
- }
-
- @failingTest
- void test_parseClassDeclaration_extendsAndWithAndImplements() {
- super.test_parseClassDeclaration_extendsAndWithAndImplements();
- }
-
- @failingTest
- void test_parseClassDeclaration_implements() {
- super.test_parseClassDeclaration_implements();
- }
-
- @failingTest
- void test_parseClassDeclaration_metadata() {
- super.test_parseClassDeclaration_metadata();
- }
-
- @failingTest
- void test_parseClassDeclaration_native() {
- super.test_parseClassDeclaration_native();
- }
-
- @failingTest
- void test_parseClassDeclaration_nonEmpty() {
- super.test_parseClassDeclaration_nonEmpty();
- }
-
- @failingTest
- void test_parseClassDeclaration_typeAlias_implementsC() {
- super.test_parseClassDeclaration_typeAlias_implementsC();
- }
-
- @failingTest
- void test_parseClassDeclaration_typeAlias_withB() {
- super.test_parseClassDeclaration_typeAlias_withB();
- }
-
- @failingTest
- void test_parseClassDeclaration_typeParameters() {
- super.test_parseClassDeclaration_typeParameters();
- }
-
- @failingTest
- void test_parseClassDeclaration_withDocumentationComment() {
- super.test_parseClassDeclaration_withDocumentationComment();
- }
-
- @failingTest
- void test_parseClassTypeAlias_withDocumentationComment() {
- super.test_parseClassTypeAlias_withDocumentationComment();
- }
-
- @failingTest
- void test_parseCompilationUnit_abstractAsPrefix_parameterized() {
- super.test_parseCompilationUnit_abstractAsPrefix_parameterized();
- }
-
- @failingTest
- void test_parseCompilationUnit_builtIn_asFunctionName() {
- super.test_parseCompilationUnit_builtIn_asFunctionName();
- }
-
- @failingTest
- void test_parseCompilationUnit_builtIn_asFunctionName_withTypeParameter() {
- super.test_parseCompilationUnit_builtIn_asFunctionName_withTypeParameter();
- }
-
- @failingTest
- void test_parseCompilationUnit_builtIn_asGetter() {
- super.test_parseCompilationUnit_builtIn_asGetter();
- }
-
- @failingTest
- void test_parseCompilationUnit_directives_multiple() {
- super.test_parseCompilationUnit_directives_multiple();
- }
-
- @failingTest
- void test_parseCompilationUnit_directives_single() {
- super.test_parseCompilationUnit_directives_single();
- }
-
- @failingTest
- void test_parseCompilationUnit_empty() {
- super.test_parseCompilationUnit_empty();
- }
-
- @failingTest
- void test_parseCompilationUnit_exportAsPrefix() {
- super.test_parseCompilationUnit_exportAsPrefix();
- }
-
- @failingTest
- void test_parseCompilationUnit_exportAsPrefix_parameterized() {
- super.test_parseCompilationUnit_exportAsPrefix_parameterized();
- }
-
- @failingTest
- void test_parseCompilationUnit_operatorAsPrefix_parameterized() {
- super.test_parseCompilationUnit_operatorAsPrefix_parameterized();
- }
-
- @failingTest
- void test_parseCompilationUnit_pseudo_prefixed() {
- super.test_parseCompilationUnit_pseudo_prefixed();
- }
-
- @failingTest
- void test_parseCompilationUnit_script() {
- super.test_parseCompilationUnit_script();
- }
-
- @failingTest
- void test_parseCompilationUnit_skipFunctionBody_withInterpolation() {
- super.test_parseCompilationUnit_skipFunctionBody_withInterpolation();
- }
-
- @failingTest
- void test_parseCompilationUnit_topLevelDeclaration() {
- super.test_parseCompilationUnit_topLevelDeclaration();
- }
-
- @failingTest
- void test_parseCompilationUnit_typedefAsPrefix() {
- super.test_parseCompilationUnit_typedefAsPrefix();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_abstractAsPrefix() {
- super.test_parseCompilationUnitMember_abstractAsPrefix();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_class() {
- super.test_parseCompilationUnitMember_class();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_classTypeAlias() {
- super.test_parseCompilationUnitMember_classTypeAlias();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_constVariable() {
- super.test_parseCompilationUnitMember_constVariable();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_expressionFunctionBody_tokens() {
- super.test_parseCompilationUnitMember_expressionFunctionBody_tokens();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_finalVariable() {
- super.test_parseCompilationUnitMember_finalVariable();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_function_external_noType() {
- super.test_parseCompilationUnitMember_function_external_noType();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_function_external_type() {
- super.test_parseCompilationUnitMember_function_external_type();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_function_generic_noReturnType() {
- super.test_parseCompilationUnitMember_function_generic_noReturnType();
- }
-
- @failingTest
- void
- test_parseCompilationUnitMember_function_generic_noReturnType_annotated() {
- super
- .test_parseCompilationUnitMember_function_generic_noReturnType_annotated();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_function_generic_returnType() {
- super.test_parseCompilationUnitMember_function_generic_returnType();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_function_generic_void() {
- super.test_parseCompilationUnitMember_function_generic_void();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_function_gftReturnType() {
- super.test_parseCompilationUnitMember_function_gftReturnType();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_function_noReturnType() {
- super.test_parseCompilationUnitMember_function_noReturnType();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_function_noType() {
- super.test_parseCompilationUnitMember_function_noType();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_function_type() {
- super.test_parseCompilationUnitMember_function_type();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_function_void() {
- super.test_parseCompilationUnitMember_function_void();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_getter_external_noType() {
- super.test_parseCompilationUnitMember_getter_external_noType();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_getter_external_type() {
- super.test_parseCompilationUnitMember_getter_external_type();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_getter_noType() {
- super.test_parseCompilationUnitMember_getter_noType();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_getter_type() {
- super.test_parseCompilationUnitMember_getter_type();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_setter_external_noType() {
- super.test_parseCompilationUnitMember_setter_external_noType();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_setter_external_type() {
- super.test_parseCompilationUnitMember_setter_external_type();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_setter_noType() {
- super.test_parseCompilationUnitMember_setter_noType();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_setter_type() {
- super.test_parseCompilationUnitMember_setter_type();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_typeAlias_abstract() {
- super.test_parseCompilationUnitMember_typeAlias_abstract();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_typeAlias_generic() {
- super.test_parseCompilationUnitMember_typeAlias_generic();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_typeAlias_implements() {
- super.test_parseCompilationUnitMember_typeAlias_implements();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_typeAlias_noImplements() {
- super.test_parseCompilationUnitMember_typeAlias_noImplements();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_typedef() {
- super.test_parseCompilationUnitMember_typedef();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_typedef_withDocComment() {
- super.test_parseCompilationUnitMember_typedef_withDocComment();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_typedVariable() {
- super.test_parseCompilationUnitMember_typedVariable();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_variable() {
- super.test_parseCompilationUnitMember_variable();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_variable_gftType_gftReturnType() {
- super.test_parseCompilationUnitMember_variable_gftType_gftReturnType();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_variable_gftType_noReturnType() {
- super.test_parseCompilationUnitMember_variable_gftType_noReturnType();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_variable_withDocumentationComment() {
- super.test_parseCompilationUnitMember_variable_withDocumentationComment();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_variableGet() {
- super.test_parseCompilationUnitMember_variableGet();
- }
-
- @failingTest
- void test_parseCompilationUnitMember_variableSet() {
- super.test_parseCompilationUnitMember_variableSet();
- }
-
- @failingTest
- void test_parseDirective_export() {
- super.test_parseDirective_export();
- }
-
- @failingTest
- void test_parseDirective_export_withDocComment() {
- super.test_parseDirective_export_withDocComment();
- }
-
- @failingTest
- void test_parseDirective_import() {
- super.test_parseDirective_import();
- }
-
- @failingTest
- void test_parseDirective_library() {
- super.test_parseDirective_library();
- }
-
- @failingTest
- void test_parseDirective_library_1_component() {
- super.test_parseDirective_library_1_component();
- }
-
- @failingTest
- void test_parseDirective_library_2_components() {
- super.test_parseDirective_library_2_components();
- }
-
- @failingTest
- void test_parseDirective_library_3_components() {
- super.test_parseDirective_library_3_components();
- }
-
- @failingTest
- void test_parseDirective_library_withDocumentationComment() {
- super.test_parseDirective_library_withDocumentationComment();
- }
-
- @failingTest
- void test_parseDirective_part() {
- super.test_parseDirective_part();
- }
-
- @failingTest
- void test_parseDirective_part_of_1_component() {
- super.test_parseDirective_part_of_1_component();
- }
-
- @failingTest
- void test_parseDirective_part_of_2_components() {
- super.test_parseDirective_part_of_2_components();
- }
-
- @failingTest
- void test_parseDirective_part_of_3_components() {
- super.test_parseDirective_part_of_3_components();
- }
-
- @failingTest
- void test_parseDirective_part_of_withDocumentationComment() {
- super.test_parseDirective_part_of_withDocumentationComment();
- }
-
- @failingTest
- void test_parseDirective_part_withDocumentationComment() {
- super.test_parseDirective_part_withDocumentationComment();
- }
-
- @failingTest
- void test_parseDirective_partOf() {
- super.test_parseDirective_partOf();
- }
-
- @failingTest
- void test_parseDirectives_complete() {
- super.test_parseDirectives_complete();
- }
-
- @failingTest
- void test_parseDirectives_empty() {
- super.test_parseDirectives_empty();
- }
-
- @failingTest
- void test_parseDirectives_mixed() {
- super.test_parseDirectives_mixed();
- }
-
- @failingTest
- void test_parseDirectives_multiple() {
- super.test_parseDirectives_multiple();
- }
-
- @failingTest
- void test_parseDirectives_script() {
- super.test_parseDirectives_script();
- }
-
- @failingTest
- void test_parseDirectives_single() {
- super.test_parseDirectives_single();
- }
-
- @failingTest
- void test_parseDirectives_topLevelDeclaration() {
- super.test_parseDirectives_topLevelDeclaration();
- }
-
- @failingTest
- void test_parseEnumDeclaration_one() {
- super.test_parseEnumDeclaration_one();
- }
-
- @failingTest
- void test_parseEnumDeclaration_trailingComma() {
- super.test_parseEnumDeclaration_trailingComma();
- }
-
- @failingTest
- void test_parseEnumDeclaration_two() {
- super.test_parseEnumDeclaration_two();
- }
-
- @failingTest
- void test_parseEnumDeclaration_withDocComment_onEnum() {
- super.test_parseEnumDeclaration_withDocComment_onEnum();
- }
-
- @failingTest
- void test_parseEnumDeclaration_withDocComment_onValue() {
- super.test_parseEnumDeclaration_withDocComment_onValue();
- }
-
- @failingTest
- void test_parseExportDirective_configuration_multiple() {
- super.test_parseExportDirective_configuration_multiple();
- }
-
- @failingTest
- void test_parseExportDirective_configuration_single() {
- super.test_parseExportDirective_configuration_single();
- }
-
- @failingTest
- void test_parseExportDirective_hide() {
- super.test_parseExportDirective_hide();
- }
-
- @failingTest
- void test_parseExportDirective_hide_show() {
- super.test_parseExportDirective_hide_show();
- }
-
- @failingTest
- void test_parseExportDirective_noCombinator() {
- super.test_parseExportDirective_noCombinator();
- }
-
- @failingTest
- void test_parseExportDirective_show() {
- super.test_parseExportDirective_show();
- }
-
- @failingTest
- void test_parseExportDirective_show_hide() {
- super.test_parseExportDirective_show_hide();
- }
-
- @failingTest
- void test_parseFunctionDeclaration_function() {
- super.test_parseFunctionDeclaration_function();
- }
-
- @failingTest
- void test_parseFunctionDeclaration_functionWithTypeParameters() {
- super.test_parseFunctionDeclaration_functionWithTypeParameters();
- }
-
- @failingTest
- void test_parseFunctionDeclaration_getter() {
- super.test_parseFunctionDeclaration_getter();
- }
-
- @failingTest
- void test_parseFunctionDeclaration_metadata() {
- super.test_parseFunctionDeclaration_metadata();
- }
-
- @failingTest
- void test_parseFunctionDeclaration_setter() {
- super.test_parseFunctionDeclaration_setter();
- }
-
- @failingTest
- void test_parseGenericTypeAlias_noTypeParameters() {
- super.test_parseGenericTypeAlias_noTypeParameters();
- }
-
- @failingTest
- void test_parseGenericTypeAlias_typeParameters() {
- super.test_parseGenericTypeAlias_typeParameters();
- }
-
- @failingTest
- void test_parseImportDirective_configuration_multiple() {
- super.test_parseImportDirective_configuration_multiple();
- }
-
- @failingTest
- void test_parseImportDirective_configuration_single() {
- super.test_parseImportDirective_configuration_single();
- }
-
- @failingTest
- void test_parseImportDirective_deferred() {
- super.test_parseImportDirective_deferred();
- }
-
- @failingTest
- void test_parseImportDirective_hide() {
- super.test_parseImportDirective_hide();
- }
-
- @failingTest
- void test_parseImportDirective_noCombinator() {
- super.test_parseImportDirective_noCombinator();
- }
-
- @failingTest
- void test_parseImportDirective_prefix() {
- super.test_parseImportDirective_prefix();
- }
-
- @failingTest
- void test_parseImportDirective_prefix_hide_show() {
- super.test_parseImportDirective_prefix_hide_show();
- }
-
- @failingTest
- void test_parseImportDirective_prefix_show_hide() {
- super.test_parseImportDirective_prefix_show_hide();
- }
-
- @failingTest
- void test_parseImportDirective_show() {
- super.test_parseImportDirective_show();
- }
-
- @failingTest
- void test_parseLibraryDirective() {
- super.test_parseLibraryDirective();
- }
-
- @failingTest
- void test_parsePartDirective() {
- super.test_parsePartDirective();
- }
-
- @failingTest
- void test_parsePartOfDirective_name() {
- super.test_parsePartOfDirective_name();
- }
-
- @failingTest
- void test_parsePartOfDirective_uri() {
- super.test_parsePartOfDirective_uri();
- }
-
- @failingTest
- void test_parseTypeAlias_function_noParameters() {
- super.test_parseTypeAlias_function_noParameters();
- }
-
- @failingTest
- void test_parseTypeAlias_function_noReturnType() {
- super.test_parseTypeAlias_function_noReturnType();
- }
-
- @failingTest
- void test_parseTypeAlias_function_parameterizedReturnType() {
- super.test_parseTypeAlias_function_parameterizedReturnType();
- }
-
- @failingTest
- void test_parseTypeAlias_function_parameters() {
- super.test_parseTypeAlias_function_parameters();
- }
-
- @failingTest
- void test_parseTypeAlias_function_typeParameters() {
- super.test_parseTypeAlias_function_typeParameters();
- }
-
- @failingTest
- void test_parseTypeAlias_function_voidReturnType() {
- super.test_parseTypeAlias_function_voidReturnType();
- }
-
- @failingTest
- void test_parseTypeAlias_genericFunction_noParameters() {
- super.test_parseTypeAlias_genericFunction_noParameters();
- }
-
- @failingTest
- void test_parseTypeAlias_genericFunction_noReturnType() {
- super.test_parseTypeAlias_genericFunction_noReturnType();
- }
-
- @failingTest
- void test_parseTypeAlias_genericFunction_parameterizedReturnType() {
- super.test_parseTypeAlias_genericFunction_parameterizedReturnType();
- }
-
- @failingTest
- void test_parseTypeAlias_genericFunction_parameters() {
- super.test_parseTypeAlias_genericFunction_parameters();
- }
-
- @failingTest
- void test_parseTypeAlias_genericFunction_typeParameters() {
- super.test_parseTypeAlias_genericFunction_typeParameters();
- }
-
- @failingTest
- void test_parseTypeAlias_genericFunction_typeParameters_noParameters() {
- super.test_parseTypeAlias_genericFunction_typeParameters_noParameters();
- }
-
- @failingTest
- void test_parseTypeAlias_genericFunction_typeParameters_noReturnType() {
- super.test_parseTypeAlias_genericFunction_typeParameters_noReturnType();
- }
-
- @failingTest
- void
- test_parseTypeAlias_genericFunction_typeParameters_parameterizedReturnType() {
- super
- .test_parseTypeAlias_genericFunction_typeParameters_parameterizedReturnType();
- }
-
- @failingTest
- void test_parseTypeAlias_genericFunction_typeParameters_parameters() {
- super.test_parseTypeAlias_genericFunction_typeParameters_parameters();
- }
-
- @failingTest
- void test_parseTypeAlias_genericFunction_typeParameters_typeParameters() {
- super.test_parseTypeAlias_genericFunction_typeParameters_typeParameters();
- }
-
- @failingTest
- void test_parseTypeAlias_genericFunction_typeParameters_voidReturnType() {
- super.test_parseTypeAlias_genericFunction_typeParameters_voidReturnType();
- }
-
- @failingTest
- void test_parseTypeAlias_genericFunction_voidReturnType() {
- super.test_parseTypeAlias_genericFunction_voidReturnType();
- }
-
- @failingTest
- void test_parseTypeAlias_genericFunction_withDocComment() {
- super.test_parseTypeAlias_genericFunction_withDocComment();
- }
-
- @failingTest
- void test_parseTypeVariable_withDocumentationComment() {
- super.test_parseTypeVariable_withDocumentationComment();
- }
-}
diff --git a/pkg/analyzer/test/generated/static_type_warning_code_kernel_test.dart b/pkg/analyzer/test/generated/static_type_warning_code_kernel_test.dart
index 234c2ff..b0bd5c2 100644
--- a/pkg/analyzer/test/generated/static_type_warning_code_kernel_test.dart
+++ b/pkg/analyzer/test/generated/static_type_warning_code_kernel_test.dart
@@ -261,20 +261,6 @@
@override
@failingTest
- test_invalidAssignment_defaultValue_named() async {
- // UnimplementedError: kernel: (Let) let final dynamic #t1 = 0 in let ...
- await super.test_invalidAssignment_defaultValue_named();
- }
-
- @override
- @failingTest
- test_invalidAssignment_defaultValue_optional() async {
- // UnimplementedError: kernel: (Let) let final dynamic #t2 = 0 in let ...
- await super.test_invalidAssignment_defaultValue_optional();
- }
-
- @override
- @failingTest
test_invalidAssignment_dynamic() async {
// Bad state: No reference information for dynamic at 11
await super.test_invalidAssignment_dynamic();
@@ -719,6 +705,13 @@
@override
@failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_undefinedGetter_proxy_annotation_fakeProxy() async {
+ await super.test_undefinedGetter_proxy_annotation_fakeProxy();
+ }
+
+ @override
+ @failingTest
test_undefinedGetter_static() async {
// Bad state: No reference information for A at 19
await super.test_undefinedGetter_static();
diff --git a/pkg/analyzer/test/generated/strong_mode_kernel_test.dart b/pkg/analyzer/test/generated/strong_mode_kernel_test.dart
index 9157b6d..0e94294 100644
--- a/pkg/analyzer/test/generated/strong_mode_kernel_test.dart
+++ b/pkg/analyzer/test/generated/strong_mode_kernel_test.dart
@@ -653,13 +653,6 @@
@override
@failingTest
- test_notInstantiatedBound_ok_class_function() {
- // Failed to resolve 1 nodes
- return super.test_notInstantiatedBound_ok_class_function();
- }
-
- @override
- @failingTest
test_objectMethodOnFunctions_Typedef() {
// UnimplementedError: TODO(paulberry): resynthesize generic typedef
return super.test_objectMethodOnFunctions_Typedef();
diff --git a/pkg/analyzer/test/generated/strong_mode_test.dart b/pkg/analyzer/test/generated/strong_mode_test.dart
index 1414b83..a84ddc6 100644
--- a/pkg/analyzer/test/generated/strong_mode_test.dart
+++ b/pkg/analyzer/test/generated/strong_mode_test.dart
@@ -4107,7 +4107,7 @@
test_notInstantiatedBound_ok_class_function() async {
String code = r'''
-class A<T extends void Function<Z>()> {}
+class A<T extends void Function()> {}
class B<T extends A> {}
''';
await resolveTestUnit(code);
diff --git a/pkg/analyzer/test/generated/test_all.dart b/pkg/analyzer/test/generated/test_all.dart
index ef889c4..52a3081 100644
--- a/pkg/analyzer/test/generated/test_all.dart
+++ b/pkg/analyzer/test/generated/test_all.dart
@@ -42,7 +42,6 @@
import 'non_hint_code_test.dart' as non_hint_code_test;
import 'package_test.dart' as package_test;
import 'parser_fasta_test.dart' as parser_fasta_test;
-import 'parser_forest_test.dart' as parser_forest_test;
import 'parser_test.dart' as parser_test;
import 'resolver_driver_test.dart' as resolver_driver_test;
import 'resolver_kernel_test.dart' as resolver_kernel_test;
@@ -108,7 +107,6 @@
non_hint_code_test.main();
package_test.main();
parser_fasta_test.main();
- parser_forest_test.main();
parser_test.main();
resolver_driver_test.main();
resolver_kernel_test.main();
diff --git a/pkg/analyzer/test/src/dart/analysis/driver_kernel_test.dart b/pkg/analyzer/test/src/dart/analysis/driver_kernel_test.dart
index 830cd0f..4bb1b75 100644
--- a/pkg/analyzer/test/src/dart/analysis/driver_kernel_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/driver_kernel_test.dart
@@ -31,8 +31,6 @@
@override
bool get useCFE => true;
-// @failingTest
-// @potentialAnalyzerProblem
@override
test_asyncChangesDuringAnalysis_getErrors() async {
// TODO(brianwilkerson) Re-enable this test. It was disabled because it
@@ -54,6 +52,13 @@
// await super.test_asyncChangesDuringAnalysis_getErrors();
}
+ @override
+ @failingTest
+ @potentialAnalyzerProblem
+ test_const_annotation_notConstConstructor() async {
+ await super.test_const_annotation_notConstConstructor();
+ }
+
@failingTest
@potentialAnalyzerProblem
@override
@@ -61,6 +66,27 @@
await super.test_const_annotation_withArgs();
}
+ @override
+ @failingTest
+ @potentialAnalyzerProblem
+ test_const_annotation_withoutArgs() async {
+ await super.test_const_annotation_withoutArgs();
+ }
+
+ @override
+ @failingTest
+ @potentialAnalyzerProblem
+ test_const_circular_reference() async {
+ await super.test_const_circular_reference();
+ }
+
+ @override
+ @failingTest
+ @potentialAnalyzerProblem
+ test_const_dependency_sameUnit() async {
+ await super.test_const_dependency_sameUnit();
+ }
+
@failingTest
@potentialAnalyzerProblem
@override
@@ -82,6 +108,13 @@
await super.test_const_implicitSuperConstructorInvocation();
}
+ @override
+ @failingTest
+ @potentialAnalyzerProblem
+ test_const_simple_topLevelVariable() async {
+ await super.test_const_simple_topLevelVariable();
+ }
+
@failingTest
@potentialAnalyzerProblem
@override
diff --git a/pkg/analyzer/test/src/dart/analysis/driver_resolution_kernel_test.dart b/pkg/analyzer/test/src/dart/analysis/driver_resolution_kernel_test.dart
index 2422f69..ce897ed 100644
--- a/pkg/analyzer/test/src/dart/analysis/driver_resolution_kernel_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/driver_resolution_kernel_test.dart
@@ -23,6 +23,27 @@
@override
@failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_annotation() async {
+ await super.test_annotation();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_annotation_constructor_withNestedConstructorInvocation() async {
+ await super.test_annotation_constructor_withNestedConstructorInvocation();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_annotation_kind_reference() async {
+ await super.test_annotation_kind_reference();
+ }
+
+ @override
+ @failingTest
@potentialAnalyzerProblem
test_annotation_prefixed_classConstructor() {
// TODO(paulberry): broken because prefixes are not working properly
diff --git a/pkg/analyzer/test/src/dart/analysis/search_test.dart b/pkg/analyzer/test/src/dart/analysis/search_test.dart
index d667f0e..d3573f1 100644
--- a/pkg/analyzer/test/src/dart/analysis/search_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/search_test.dart
@@ -1646,6 +1646,23 @@
}
}
+ test_subtypes_partWithoutLibrary() async {
+ await _resolveTestUnit('''
+part of lib;
+
+class A {}
+class B extends A {}
+''');
+ ClassElement a = _findElement('A');
+
+ List<SubtypeResult> subtypes = await driver.search.subtypes(type: a);
+ expect(subtypes, hasLength(1));
+
+ SubtypeResult b = subtypes.singleWhere((r) => r.name == 'B');
+ expect(b.libraryUri, testUri);
+ expect(b.id, '$testUri;$testUri;B');
+ }
+
test_subtypes_discover() async {
var pathT = _p('/test/lib/t.dart');
var pathA = _p('/aaa/lib/a.dart');
diff --git a/pkg/analyzer/test/src/fasta/body_builder_test_helper.dart b/pkg/analyzer/test/src/fasta/body_builder_test_helper.dart
index 66b2d52..22a2cc8 100644
--- a/pkg/analyzer/test/src/fasta/body_builder_test_helper.dart
+++ b/pkg/analyzer/test/src/fasta/body_builder_test_helper.dart
@@ -5,41 +5,24 @@
import 'dart:async';
import 'dart:io' show File;
-import 'package:analyzer/analyzer.dart';
-import 'package:analyzer/dart/ast/ast.dart';
import 'package:analyzer/dart/element/element.dart';
import 'package:analyzer/src/dart/element/element.dart';
import 'package:analyzer/src/dart/element/type.dart';
-import 'package:analyzer/src/fasta/ast_body_builder.dart';
-import 'package:analyzer/src/generated/parser.dart' as analyzer;
-import 'package:analyzer/src/generated/resolver.dart';
import "package:front_end/src/api_prototype/front_end.dart";
import "package:front_end/src/api_prototype/memory_file_system.dart";
import "package:front_end/src/base/processed_options.dart";
import "package:front_end/src/compute_platform_binaries_location.dart";
import 'package:front_end/src/fasta/compiler_context.dart';
-import 'package:front_end/src/fasta/constant_context.dart';
import 'package:front_end/src/fasta/dill/dill_target.dart';
import "package:front_end/src/fasta/fasta_codes.dart";
-import 'package:front_end/src/fasta/kernel/forest.dart' hide Identifier;
-import 'package:front_end/src/fasta/kernel/kernel_builder.dart';
import "package:front_end/src/fasta/kernel/kernel_target.dart";
-import 'package:front_end/src/fasta/modifier.dart' as Modifier;
-import 'package:front_end/src/fasta/parser/async_modifier.dart';
-import 'package:front_end/src/fasta/parser/parser.dart';
-import 'package:front_end/src/fasta/scanner.dart';
import 'package:front_end/src/fasta/ticker.dart';
-import 'package:front_end/src/fasta/type_inference/type_inferrer.dart';
-import 'package:front_end/src/fasta/type_inference/type_schema_environment.dart';
import 'package:front_end/src/fasta/uri_translator_impl.dart';
import 'package:kernel/class_hierarchy.dart' as kernel;
import 'package:kernel/core_types.dart' as kernel;
import 'package:kernel/kernel.dart' as kernel;
import 'package:test/test.dart';
-import '../../generated/parser_test.dart';
-import '../../generated/test_support.dart';
-
Element _buildElement(kernel.Class coreType) {
ClassElementImpl element =
new ClassElementImpl(coreType.name, coreType.fileOffset);
@@ -54,7 +37,6 @@
class CompilerTestContext extends CompilerContext {
KernelTarget kernelTarget;
- TypeProvider _typeProvider;
CompilerTestContext(ProcessedOptions options) : super(options);
@@ -139,9 +121,6 @@
]) {
map[coreType.name] = _buildElement(coreType);
}
- Namespace namespace = new Namespace(map);
- c._typeProvider =
- new TypeProviderImpl.forNamespaces(namespace, namespace);
T result;
Completer<T> completer = new Completer<T>();
@@ -160,651 +139,3 @@
static CompilerTestContext get current => CompilerContext.current;
}
-
-/// Implementation of [AbstractParserTestCase] specialized for testing building
-/// Analyzer AST using the fasta [Forest] API.
-class FastaBodyBuilderTestCase extends Object
- with ParserTestHelpers
- implements AbstractParserTestCase {
- final bool resolveTypes;
-
- String content;
-
- /// The expected offset of the next token to be parsed after the parser has
- /// finished parsing, or `null` (the default) if EOF is expected.
- int expectedEndOffset;
-
- @override
- void set enableGenericMethodComments(_) {
- // Ignored.
- }
-
- FastaBodyBuilderTestCase(this.resolveTypes);
-
- analyzer.Parser get parser => new ParserProxy(this);
-
- TypeProvider get typeProvider => CompilerTestContext.current._typeProvider;
-
- bool get usingFastaParser => true;
-
- @override
- void assertNoErrors() {
- // TODO(brianwilkerson) Implement this.
- }
-
- void createParser(String content, {int expectedEndOffset}) {
- this.content = content;
- this.expectedEndOffset = expectedEndOffset;
- }
-
- @override
- void expectNotNullIfNoErrors(Object result) {
- // TODO(brianwilkerson) Implement this.
- }
-
- @override
- ExpectedError expectedError(ErrorCode code, int offset, int length) {
- return new ExpectedError(code, offset, length);
- }
-
- noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation);
-
- @override
- Expression parseAdditiveExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- Expression parseAssignableExpression(String code, bool primaryAllowed) {
- return parseExpression(code);
- }
-
- @override
- Expression parseAssignableSelector(String code, bool optional,
- {bool allowConditional: true}) {
- return parseExpression(code);
- }
-
- @override
- AwaitExpression parseAwaitExpression(String code) {
- return parseExpression(code, inAsync: true);
- }
-
- @override
- Expression parseBitwiseAndExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- Expression parseBitwiseOrExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- Expression parseBitwiseXorExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- Expression parseCascadeSection(String code) {
- return parseExpression(code);
- }
-
- @override
- CompilationUnit parseCompilationUnit(String source,
- {List<ErrorCode> codes, List<ExpectedError> errors}) {
- return _parse(source, (parser, token) => parser.parseUnit(token.next));
- }
-
- @override
- ConditionalExpression parseConditionalExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- Expression parseConstExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- ConstructorInitializer parseConstructorInitializer(String code) {
- throw new UnimplementedError();
- }
-
- @override
- CompilationUnit parseDirectives(String source,
- [List<ErrorCode> errorCodes = const <ErrorCode>[]]) {
- return parseCompilationUnit(content, codes: errorCodes);
- }
-
- @override
- BinaryExpression parseEqualityExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- Expression parseExpression(String source,
- {List<ErrorCode> codes,
- List<ExpectedError> errors,
- int expectedEndOffset,
- bool inAsync: false,
- bool inCatchBlock: false}) {
- // TODO(brianwilkerson) Check error codes.
- Object result = _parse(
- source, (parser, token) => parser.parseExpression(token),
- inAsync: inAsync, inCatchBlock: inCatchBlock);
- if (result is Generator) {
- result = (result as Generator).buildForEffect();
- }
- if (result is! Expression) {
- throw new StateError('Expected Expression, found ${result.runtimeType}');
- }
- return result;
- }
-
- @override
- List<Expression> parseExpressionList(String code) {
- throw new UnimplementedError();
- }
-
- @override
- Expression parseExpressionWithoutCascade(String code) {
- return parseExpression(code);
- }
-
- @override
- FormalParameter parseFormalParameter(String code, ParameterKind kind,
- {List<ErrorCode> errorCodes: const <ErrorCode>[]}) {
- throw new UnimplementedError();
- }
-
- @override
- FormalParameterList parseFormalParameterList(String code,
- {bool inFunctionType: false,
- List<ErrorCode> errorCodes: const <ErrorCode>[],
- List<ExpectedError> errors}) {
- throw new UnimplementedError();
- }
-
- @override
- CompilationUnitMember parseFullCompilationUnitMember() {
- CompilationUnit unit = parseCompilationUnit(content);
- expect(unit.directives, hasLength(0));
- expect(unit.declarations, hasLength(1));
- return unit.declarations[0];
- }
-
- @override
- Directive parseFullDirective() {
- CompilationUnit unit = parseCompilationUnit(content);
- expect(unit.directives, hasLength(1));
- expect(unit.declarations, hasLength(0));
- return unit.directives[0];
- }
-
- @override
- FunctionExpression parseFunctionExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- InstanceCreationExpression parseInstanceCreationExpression(
- String code, Token newToken) {
- return parseExpression(code);
- }
-
- @override
- ListLiteral parseListLiteral(
- Token token, String typeArgumentsCode, String code) {
- StringBuffer buffer = new StringBuffer();
- if (token != null) {
- buffer.write(token.lexeme);
- buffer.write(' ');
- }
- if (typeArgumentsCode != null) {
- buffer.write(typeArgumentsCode);
- }
- buffer.write(code);
- return parseExpression(buffer.toString());
- }
-
- @override
- TypedLiteral parseListOrMapLiteral(Token modifier, String code) {
- return parseExpression(code);
- }
-
- @override
- Expression parseLogicalAndExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- Expression parseLogicalOrExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- MapLiteral parseMapLiteral(
- Token token, String typeArgumentsCode, String code) {
- StringBuffer buffer = new StringBuffer();
- if (token != null) {
- buffer.write(token.lexeme);
- buffer.write(' ');
- }
- if (typeArgumentsCode != null) {
- buffer.write(typeArgumentsCode);
- }
- buffer.write(code);
- return parseExpression(buffer.toString());
- }
-
- @override
- MapLiteralEntry parseMapLiteralEntry(String code) {
- Expression expression = parseExpression('{$code}');
- expect(expression, new isInstanceOf<MapLiteral>());
- MapLiteral literal = expression;
- expect(literal.entries, hasLength(1));
- return literal.entries[0];
- }
-
- @override
- Expression parseMultiplicativeExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- InstanceCreationExpression parseNewExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- NormalFormalParameter parseNormalFormalParameter(String code,
- {bool inFunctionType: false,
- List<ErrorCode> errorCodes: const <ErrorCode>[]}) {
- throw new UnimplementedError();
- }
-
- @override
- Expression parsePostfixExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- Identifier parsePrefixedIdentifier(String code) {
- return parseExpression(code);
- }
-
- @override
- Expression parsePrimaryExpression(String code,
- {int expectedEndOffset, List<ExpectedError> errors}) {
- return parseExpression(code,
- expectedEndOffset: expectedEndOffset, errors: errors);
- }
-
- @override
- Expression parseRelationalExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- RethrowExpression parseRethrowExpression(String code) {
- Statement statement = parseStatement(code, inCatchBlock: true);
- expect(statement, new isInstanceOf<ExpressionStatement>());
- Expression expression = (statement as ExpressionStatement).expression;
- expect(expression, new isInstanceOf<RethrowExpression>());
- return expression;
- }
-
- @override
- BinaryExpression parseShiftExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- SimpleIdentifier parseSimpleIdentifier(String code) {
- return parseExpression(code);
- }
-
- @override
- Statement parseStatement(String source,
- {bool enableLazyAssignmentOperators,
- int expectedEndOffset,
- bool inCatchBlock: true}) {
- // TODO(brianwilkerson) Check error codes.
- return _parse(source, (parser, token) => parser.parseStatement(token),
- inCatchBlock: inCatchBlock);
- }
-
- @override
- Expression parseStringLiteral(String code) {
- return parseExpression(code);
- }
-
- @override
- SymbolLiteral parseSymbolLiteral(String code) {
- return parseExpression(code);
- }
-
- @override
- Expression parseThrowExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- Expression parseThrowExpressionWithoutCascade(String code) {
- return parseExpression(code);
- }
-
- @override
- PrefixExpression parseUnaryExpression(String code) {
- return parseExpression(code);
- }
-
- @override
- VariableDeclarationList parseVariableDeclarationList(String source) {
- CompilationUnit unit = parseCompilationUnit('''
-f() {
- $source;
-}
-''');
- FunctionDeclaration function = unit.declarations[0];
- BlockFunctionBody body = function.functionExpression.body;
- VariableDeclarationStatement statement = body.block.statements[0];
- return statement.variables;
- }
-
- T _parse<T>(
- String source, void parseFunction(Parser parser, Token previousToken),
- {bool inAsync: false, bool inCatchBlock: false}) {
- ScannerResult scan = scanString(source);
-
- CompilerTestContext c = CompilerTestContext.current;
- KernelLibraryBuilder library = new KernelLibraryBuilder(
- c.entryPoint,
- c.entryPoint,
- c.kernelTarget.loader,
- null /* actualOrigin */,
- null /* enclosingLibrary */,
- );
- List<KernelTypeVariableBuilder> typeVariableBuilders =
- <KernelTypeVariableBuilder>[];
- List<KernelFormalParameterBuilder> formalParameterBuilders =
- <KernelFormalParameterBuilder>[];
- KernelProcedureBuilder procedureBuilder = new KernelProcedureBuilder(
- null /* metadata */,
- Modifier.staticMask /* or Modifier.varMask */,
- c.kernelTarget.dynamicType,
- "analyzerTest",
- typeVariableBuilders,
- formalParameterBuilders,
- kernel.ProcedureKind.Method,
- library,
- -1 /* charOffset */,
- -1 /* charOpenParenOffset */,
- -1 /* charEndOffset */);
-
- TypeInferrerDisabled typeInferrer =
- new TypeInferrerDisabled(new TypeSchemaEnvironment(
- c.kernelTarget.loader.coreTypes,
- c.kernelTarget.loader.hierarchy,
- // TODO(danrubel): Enable strong mode.
- false /* strong mode */,
- ));
-
- AstBodyBuilder builder = new AstBodyBuilder(
- library,
- procedureBuilder,
- new UnlinkedScope(),
- null,
- c.kernelTarget.loader.hierarchy,
- c.kernelTarget.loader.coreTypes,
- null /* classBuilder */,
- false /* isInstanceMember */,
- null /* uri */,
- typeInferrer,
- typeProvider,
- )..constantContext = ConstantContext.none; // .inferred ?
-
- Parser parser = new Parser(builder);
- if (inAsync) {
- parser.asyncState = AsyncModifier.Async;
- }
- if (inCatchBlock) {
- builder.inCatchBlock = inCatchBlock;
- }
- parseFunction(parser, parser.syntheticPreviousToken(scan.tokens));
- // TODO(brianwilkerson) Check `expectedEndOffset` if it is not `null`.
- return builder.pop();
- }
-}
-
-/// A parser that can be used by [FastaBodyBuilderTestCase] to support the tests
-/// that still call methods on the parser directly.
-class ParserProxy implements analyzer.Parser {
- final FastaBodyBuilderTestCase testCase;
-
- ParserProxy(this.testCase);
-
- @override
- noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation);
-
- @override
- Annotation parseAnnotation() {
- CompilationUnit unit =
- testCase.parseCompilationUnit('${testCase.content} var v;');
- expect(unit.directives, hasLength(0));
- expect(unit.declarations, hasLength(1));
- expect(
- unit.declarations[0], new isInstanceOf<TopLevelVariableDeclaration>());
- TopLevelVariableDeclaration declaration = unit.declarations[0];
- expect(declaration.metadata, hasLength(1));
- return declaration.metadata[0];
- }
-
- @override
- ArgumentList parseArgumentList() {
- Expression expression = testCase.parseExpression('f${testCase.content}');
- expect(expression, new isInstanceOf<MethodInvocation>());
- MethodInvocation invocation = expression;
- return invocation.argumentList;
- }
-
- @override
- ClassMember parseClassMember(String className) {
- CompilationUnit unit = testCase
- .parseCompilationUnit('class $className { ${testCase.content} }');
- expect(unit.directives, hasLength(0));
- expect(unit.declarations, hasLength(1));
- expect(unit.declarations[0], new isInstanceOf<ClassDeclaration>());
- ClassDeclaration classDeclaration = unit.declarations[0];
- expect(classDeclaration.members, hasLength(1));
- return classDeclaration.members[0];
- }
-
- @override
- List<Combinator> parseCombinators() {
- CompilationUnit unit = testCase
- .parseCompilationUnit('import "file.dart" ${testCase.content};');
- expect(unit.directives, hasLength(1));
- expect(unit.declarations, hasLength(0));
- expect(unit.directives[0], new isInstanceOf<LibraryDirective>());
- ImportDirective directive = unit.directives[0];
- return directive.combinators;
- }
-
- @override
- CommentReference parseCommentReference(
- String referenceSource, int sourceOffset) {
- // TODO(brianwilkerson) Implement this.
- throw new UnimplementedError();
- }
-
- @override
- CompilationUnit parseCompilationUnit2() {
- return testCase.parseCompilationUnit(testCase.content);
- }
-
- @override
- Configuration parseConfiguration() {
- CompilationUnit unit = testCase
- .parseCompilationUnit('import "file.dart" ${testCase.content};');
- expect(unit.directives, hasLength(1));
- expect(unit.declarations, hasLength(0));
- expect(unit.directives[0], new isInstanceOf<LibraryDirective>());
- ImportDirective directive = unit.directives[0];
- expect(directive.configurations, hasLength(1));
- return directive.configurations[0];
- }
-
- @override
- DottedName parseDottedName() {
- CompilationUnit unit = testCase.parseCompilationUnit(
- 'import "file.dart" if (${testCase.content}) "file2.dart";');
- expect(unit.directives, hasLength(1));
- expect(unit.declarations, hasLength(0));
- expect(unit.directives[0], new isInstanceOf<LibraryDirective>());
- ImportDirective directive = unit.directives[0];
- expect(directive.configurations, hasLength(1));
- return directive.configurations[0].name;
- }
-
- @override
- ExtendsClause parseExtendsClause() {
- CompilationUnit unit =
- testCase.parseCompilationUnit('class C ${testCase.content} {}');
- expect(unit.directives, hasLength(0));
- expect(unit.declarations, hasLength(1));
- expect(unit.declarations[0], new isInstanceOf<ClassDeclaration>());
- ClassDeclaration classDeclaration = unit.declarations[0];
- return classDeclaration.extendsClause;
- }
-
- @override
- analyzer.FinalConstVarOrType parseFinalConstVarOrType(bool optional,
- {bool inFunctionType: false}) {
- // TODO(brianwilkerson) Implement this or re-write the tests.
- throw new UnimplementedError();
- }
-
- @override
- FormalParameterList parseFormalParameterList({bool inFunctionType: false}) {
- CompilationUnit unit =
- testCase.parseCompilationUnit('f${testCase.content} {}');
- expect(unit.directives, hasLength(0));
- expect(unit.declarations, hasLength(1));
- expect(unit.declarations[0], new isInstanceOf<FunctionDeclaration>());
- FunctionDeclaration function = unit.declarations[0];
- return function.functionExpression.parameters;
- }
-
- @override
- FunctionBody parseFunctionBody(bool mayBeEmpty,
- analyzer.ParserErrorCode emptyErrorCode, bool inExpression) {
- CompilationUnit unit =
- testCase.parseCompilationUnit('f() ${testCase.content}');
- expect(unit.directives, hasLength(0));
- expect(unit.declarations, hasLength(1));
- expect(unit.declarations[0], new isInstanceOf<FunctionDeclaration>());
- FunctionDeclaration declaration = unit.declarations[0];
- return declaration.functionExpression.body;
- }
-
- @override
- ImplementsClause parseImplementsClause() {
- CompilationUnit unit =
- testCase.parseCompilationUnit('class C ${testCase.content} {}');
- expect(unit.directives, hasLength(0));
- expect(unit.declarations, hasLength(1));
- expect(unit.declarations[0], new isInstanceOf<ClassDeclaration>());
- ClassDeclaration classDeclaration = unit.declarations[0];
- return classDeclaration.implementsClause;
- }
-
- @override
- analyzer.Modifiers parseModifiers() {
- // TODO(brianwilkerson) Implement this or re-write the tests (this might
- // need context to create the right kind of declaration for the modifiers).
- throw new UnimplementedError();
- }
-
- @override
- Expression parseMultiplicativeExpression() {
- return testCase.parseExpression(testCase.content);
- }
-
- @override
- Expression parsePrimaryExpression() {
- return testCase.parseExpression(testCase.content);
- }
-
- @override
- SimpleIdentifier parseSimpleIdentifier(
- {bool allowKeyword: false, bool isDeclaration: false}) {
- return testCase.parseExpression(testCase.content);
- }
-
- @override
- Statement parseStatement2() {
- return testCase.parseStatement(testCase.content);
- }
-
- @override
- TypeAnnotation parseTypeAnnotation(bool inExpression) {
- if (inExpression) {
- // TODO(brianwilkerson) As far as I can see, this path is not used.
- throw new UnimplementedError();
- }
- CompilationUnit unit =
- testCase.parseCompilationUnit('${testCase.content} x;');
- expect(unit.directives, hasLength(0));
- expect(unit.declarations, hasLength(1));
- expect(
- unit.declarations[0], new isInstanceOf<TopLevelVariableDeclaration>());
- TopLevelVariableDeclaration variable = unit.declarations[0];
- return variable.variables.type;
- }
-
- @override
- TypeArgumentList parseTypeArgumentList() {
- CompilationUnit unit =
- testCase.parseCompilationUnit('C${testCase.content} c;');
- expect(unit.directives, hasLength(0));
- expect(unit.declarations, hasLength(1));
- expect(
- unit.declarations[0], new isInstanceOf<TopLevelVariableDeclaration>());
- TopLevelVariableDeclaration variable = unit.declarations[0];
- return (variable.variables.type as TypeName).typeArguments;
- }
-
- @override
- TypeName parseTypeName(bool inExpression) {
- return parseTypeAnnotation(inExpression) as TypeName;
- }
-
- @override
- TypeParameter parseTypeParameter() {
- CompilationUnit unit =
- testCase.parseCompilationUnit('class C<${testCase.content}> {}');
- expect(unit.directives, hasLength(0));
- expect(unit.declarations, hasLength(1));
- expect(unit.declarations[0], new isInstanceOf<ClassDeclaration>());
- ClassDeclaration classDeclaration = unit.declarations[0];
- return classDeclaration.typeParameters.typeParameters[0];
- }
-
- @override
- Expression parseUnaryExpression() {
- return testCase.parseExpression(testCase.content);
- }
-
- @override
- WithClause parseWithClause() {
- CompilationUnit unit =
- testCase.parseCompilationUnit('class C ${testCase.content} {}');
- expect(unit.directives, hasLength(0));
- expect(unit.declarations, hasLength(1));
- expect(unit.declarations[0], new isInstanceOf<ClassDeclaration>());
- ClassDeclaration classDeclaration = unit.declarations[0];
- return classDeclaration.withClause;
- }
-}
diff --git a/pkg/analyzer/test/src/fasta/recovery/partial_code/assert_statement_test.dart b/pkg/analyzer/test/src/fasta/recovery/partial_code/assert_statement_test.dart
index f169558..decfa5e 100644
--- a/pkg/analyzer/test/src/fasta/recovery/partial_code/assert_statement_test.dart
+++ b/pkg/analyzer/test/src/fasta/recovery/partial_code/assert_statement_test.dart
@@ -31,13 +31,19 @@
ParserErrorCode.EXPECTED_TOKEN
],
"assert (_s_);",
- failing: allExceptEof),
+ failing: [
+ 'assert',
+ 'block',
+ 'labeled',
+ 'localFunctionNonVoid',
+ 'localFunctionVoid',
+ 'return'
+ ]),
new TestDescriptor(
'condition',
'assert (a',
[ParserErrorCode.EXPECTED_TOKEN, ScannerErrorCode.EXPECTED_TOKEN],
- "assert (a);",
- failing: allExceptEof),
+ "assert (a);"),
new TestDescriptor(
'comma',
'assert (a,',
@@ -48,14 +54,12 @@
'message',
'assert (a, b',
[ParserErrorCode.EXPECTED_TOKEN, ScannerErrorCode.EXPECTED_TOKEN],
- "assert (a, b);",
- failing: allExceptEof),
+ "assert (a, b);"),
new TestDescriptor(
'trailingComma',
'assert (a, b,',
[ParserErrorCode.EXPECTED_TOKEN, ScannerErrorCode.EXPECTED_TOKEN],
- "assert (a, b,);",
- failing: allExceptEof),
+ "assert (a, b,);"),
new TestDescriptor('rightParen', 'assert (a, b)',
[ParserErrorCode.EXPECTED_TOKEN], "assert (a, b);"),
],
diff --git a/pkg/analyzer/test/src/fasta/recovery/partial_code/field_declaration_test.dart b/pkg/analyzer/test/src/fasta/recovery/partial_code/field_declaration_test.dart
index a4ddf6b..af989fd 100644
--- a/pkg/analyzer/test/src/fasta/recovery/partial_code/field_declaration_test.dart
+++ b/pkg/analyzer/test/src/fasta/recovery/partial_code/field_declaration_test.dart
@@ -56,7 +56,13 @@
'const f =',
[ParserErrorCode.MISSING_IDENTIFIER, ParserErrorCode.EXPECTED_TOKEN],
'const f = _s_;',
- failing: allExceptEof,
+ failing: [
+ 'fieldConst',
+ 'methodNonVoid',
+ 'methodVoid',
+ 'getter',
+ 'setter'
+ ],
),
new TestDescriptor(
'const_initializer',
@@ -86,7 +92,13 @@
'final f =',
[ParserErrorCode.MISSING_IDENTIFIER, ParserErrorCode.EXPECTED_TOKEN],
'final f = _s_;',
- failing: allExceptEof,
+ failing: [
+ 'fieldConst',
+ 'methodNonVoid',
+ 'methodVoid',
+ 'getter',
+ 'setter'
+ ],
),
new TestDescriptor(
'final_initializer',
@@ -116,7 +128,13 @@
'var f =',
[ParserErrorCode.MISSING_IDENTIFIER, ParserErrorCode.EXPECTED_TOKEN],
'var f = _s_;',
- failing: allExceptEof,
+ failing: [
+ 'fieldConst',
+ 'methodNonVoid',
+ 'methodVoid',
+ 'getter',
+ 'setter'
+ ],
),
new TestDescriptor(
'var_initializer',
@@ -148,7 +166,13 @@
'A f =',
[ParserErrorCode.MISSING_IDENTIFIER, ParserErrorCode.EXPECTED_TOKEN],
'A f = _s_;',
- failing: allExceptEof,
+ failing: [
+ 'fieldConst',
+ 'methodNonVoid',
+ 'methodVoid',
+ 'getter',
+ 'setter'
+ ],
),
new TestDescriptor(
'type_initializer',
@@ -187,7 +211,13 @@
'static const f =',
[ParserErrorCode.MISSING_IDENTIFIER, ParserErrorCode.EXPECTED_TOKEN],
'static const f = _s_;',
- failing: allExceptEof,
+ failing: [
+ 'fieldConst',
+ 'methodNonVoid',
+ 'methodVoid',
+ 'getter',
+ 'setter'
+ ],
),
new TestDescriptor(
'static_const_initializer',
@@ -217,7 +247,13 @@
'static final f =',
[ParserErrorCode.MISSING_IDENTIFIER, ParserErrorCode.EXPECTED_TOKEN],
'static final f = _s_;',
- failing: allExceptEof,
+ failing: [
+ 'fieldConst',
+ 'methodNonVoid',
+ 'methodVoid',
+ 'getter',
+ 'setter'
+ ],
),
new TestDescriptor(
'static_final_initializer',
@@ -247,7 +283,13 @@
'static var f =',
[ParserErrorCode.MISSING_IDENTIFIER, ParserErrorCode.EXPECTED_TOKEN],
'static var f = _s_;',
- failing: allExceptEof,
+ failing: [
+ 'fieldConst',
+ 'methodNonVoid',
+ 'methodVoid',
+ 'getter',
+ 'setter'
+ ],
),
new TestDescriptor(
'static_var_initializer',
@@ -279,7 +321,13 @@
'static A f =',
[ParserErrorCode.MISSING_IDENTIFIER, ParserErrorCode.EXPECTED_TOKEN],
'static A f = _s_;',
- failing: allExceptEof,
+ failing: [
+ 'fieldConst',
+ 'methodNonVoid',
+ 'methodVoid',
+ 'getter',
+ 'setter'
+ ],
),
new TestDescriptor(
'static_type_initializer',
diff --git a/pkg/analyzer/test/src/fasta/recovery/partial_code/local_variable_test.dart b/pkg/analyzer/test/src/fasta/recovery/partial_code/local_variable_test.dart
index 388eec1..dc875ff 100644
--- a/pkg/analyzer/test/src/fasta/recovery/partial_code/local_variable_test.dart
+++ b/pkg/analyzer/test/src/fasta/recovery/partial_code/local_variable_test.dart
@@ -139,7 +139,14 @@
ParserErrorCode.EXPECTED_TOKEN
],
"var a = _s_;",
- failing: allExceptEof),
+ failing: [
+ 'block',
+ 'assert',
+ 'labeled',
+ 'localFunctionNonVoid',
+ 'localFunctionVoid',
+ 'return'
+ ]),
new TestDescriptor('varNameEqualsExpression', 'var a = b',
[ParserErrorCode.EXPECTED_TOKEN], "var a = b;"),
],
diff --git a/pkg/analyzer/test/src/fasta/recovery/partial_code/top_level_variable_test.dart b/pkg/analyzer/test/src/fasta/recovery/partial_code/top_level_variable_test.dart
index bb3264c..76e6f1c 100644
--- a/pkg/analyzer/test/src/fasta/recovery/partial_code/top_level_variable_test.dart
+++ b/pkg/analyzer/test/src/fasta/recovery/partial_code/top_level_variable_test.dart
@@ -214,7 +214,15 @@
ParserErrorCode.EXPECTED_TOKEN
],
"var a = _s_;",
- failing: allExceptEof,
+ failing: [
+ 'class',
+ 'typedef',
+ 'functionVoid',
+ 'functionNonVoid',
+ 'const',
+ 'getter',
+ 'setter'
+ ],
),
new TestDescriptor(
'varNameEqualsExpression',
diff --git a/pkg/analyzer/test/src/fasta/recovery/partial_code/yield_statement_test.dart b/pkg/analyzer/test/src/fasta/recovery/partial_code/yield_statement_test.dart
index 0234d1f..bc15d07 100644
--- a/pkg/analyzer/test/src/fasta/recovery/partial_code/yield_statement_test.dart
+++ b/pkg/analyzer/test/src/fasta/recovery/partial_code/yield_statement_test.dart
@@ -26,19 +26,10 @@
failing: [
'assert',
'block',
- 'break',
- 'continue',
- 'do',
- 'if',
- 'for',
'labeled',
'localFunctionNonVoid',
'localFunctionVoid',
- 'localVariable',
- 'switch',
- 'try',
'return',
- 'while'
]),
new TestDescriptor('expression', 'yield a',
[ParserErrorCode.EXPECTED_TOKEN], "yield a;"),
@@ -53,19 +44,10 @@
failing: [
'assert',
'block',
- 'break',
- 'continue',
- 'do',
- 'if',
- 'for',
'labeled',
'localFunctionNonVoid',
'localFunctionVoid',
- 'localVariable',
- 'switch',
- 'try',
'return',
- 'while'
]),
new TestDescriptor('star_expression', 'yield * a',
[ParserErrorCode.EXPECTED_TOKEN], "yield * a;"),
diff --git a/pkg/analyzer/test/src/fasta/resolution_test.dart b/pkg/analyzer/test/src/fasta/resolution_test.dart
deleted file mode 100644
index 1fbaa11..0000000
--- a/pkg/analyzer/test/src/fasta/resolution_test.dart
+++ /dev/null
@@ -1,101 +0,0 @@
-// Copyright (c) 2018, 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.
-
-import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer/dart/element/type.dart';
-import 'package:test/test.dart';
-import 'package:test_reflective_loader/test_reflective_loader.dart';
-
-import '../../generated/parser_test.dart';
-import 'body_builder_test_helper.dart';
-
-main() {
- return CompilerTestContext.runWithTestOptions((_) {
- defineReflectiveSuite(() {
- defineReflectiveTests(ResolutionTest);
- });
- });
-}
-
-/**
- * Tests of the fasta parser based on [ExpressionParserTestMixin].
- */
-@reflectiveTest
-class ResolutionTest extends FastaBodyBuilderTestCase {
- ResolutionTest() : super(true);
-
- test_booleanLiteral_false() {
- Expression result = parseExpression('false');
- expect(result, new isInstanceOf<BooleanLiteral>());
- expect((result as BooleanLiteral).staticType, typeProvider.boolType);
- }
-
- test_booleanLiteral_true() {
- Expression result = parseExpression('true');
- expect(result, new isInstanceOf<BooleanLiteral>());
- expect((result as BooleanLiteral).staticType, typeProvider.boolType);
- }
-
- test_doubleLiteral() {
- Expression result = parseExpression('4.2');
- expect(result, new isInstanceOf<DoubleLiteral>());
- expect((result as DoubleLiteral).staticType, typeProvider.doubleType);
- }
-
- test_integerLiteral() {
- Expression result = parseExpression('3');
- expect(result, new isInstanceOf<IntegerLiteral>());
- expect((result as IntegerLiteral).staticType, typeProvider.intType);
- }
-
- @failingTest
- test_listLiteral_explicitType() {
- Expression result = parseExpression('<int>[]');
- expect(result, new isInstanceOf<ListLiteral>());
- InterfaceType listType = typeProvider.listType;
- expect((result as ListLiteral).staticType,
- listType.instantiate([typeProvider.intType]));
- }
-
- @failingTest
- test_listLiteral_noType() {
- Expression result = parseExpression('[]');
- expect(result, new isInstanceOf<ListLiteral>());
- InterfaceType listType = typeProvider.listType;
- expect((result as ListLiteral).staticType,
- listType.instantiate([typeProvider.dynamicType]));
- }
-
- @failingTest
- test_mapLiteral_explicitType() {
- Expression result = parseExpression('<String, int>{}');
- expect(result, new isInstanceOf<MapLiteral>());
- InterfaceType mapType = typeProvider.mapType;
- expect((result as MapLiteral).staticType,
- mapType.instantiate([typeProvider.stringType, typeProvider.intType]));
- }
-
- @failingTest
- test_mapLiteral_noType() {
- Expression result = parseExpression('{}');
- expect(result, new isInstanceOf<MapLiteral>());
- InterfaceType mapType = typeProvider.mapType;
- expect(
- (result as MapLiteral).staticType,
- mapType
- .instantiate([typeProvider.dynamicType, typeProvider.dynamicType]));
- }
-
- test_nullLiteral() {
- Expression result = parseExpression('null');
- expect(result, new isInstanceOf<NullLiteral>());
- expect((result as NullLiteral).staticType, typeProvider.nullType);
- }
-
- test_simpleStringLiteral() {
- Expression result = parseExpression('"abc"');
- expect(result, new isInstanceOf<SimpleStringLiteral>());
- expect((result as SimpleStringLiteral).staticType, typeProvider.stringType);
- }
-}
diff --git a/pkg/analyzer/test/src/fasta/test_all.dart b/pkg/analyzer/test/src/fasta/test_all.dart
index 37ccad1..b9f73b5 100644
--- a/pkg/analyzer/test/src/fasta/test_all.dart
+++ b/pkg/analyzer/test/src/fasta/test_all.dart
@@ -7,13 +7,11 @@
import 'ast_builder_test.dart' as ast_builder;
import 'message_coverage_test.dart' as message_coverage;
import 'recovery/test_all.dart' as recovery;
-import 'resolution_test.dart' as resolution;
main() {
defineReflectiveSuite(() {
ast_builder.main();
message_coverage.main();
recovery.main();
- resolution.main();
}, name: 'fasta');
}
diff --git a/pkg/analyzer/test/src/summary/resynthesize_kernel_test.dart b/pkg/analyzer/test/src/summary/resynthesize_kernel_test.dart
index 9a2a5e1..f594ed6 100644
--- a/pkg/analyzer/test/src/summary/resynthesize_kernel_test.dart
+++ b/pkg/analyzer/test/src/summary/resynthesize_kernel_test.dart
@@ -29,11 +29,9 @@
import 'resynthesize_common.dart';
main() {
- // TODO(brianwilkerson) Either remove the following test, or uncomment it if
- // we get it working under Dart2 semantics.
-// defineReflectiveSuite(() {
-// defineReflectiveTests(ResynthesizeKernelStrongTest);
-// });
+ defineReflectiveSuite(() {
+ defineReflectiveTests(ResynthesizeKernelStrongTest);
+ });
}
/// Tests marked with this annotation fail because they test features that
@@ -97,6 +95,27 @@
}
@override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_class_constructor_fieldFormal_named_withDefault() async {
+ await super.test_class_constructor_fieldFormal_named_withDefault();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_class_constructor_fieldFormal_optional_withDefault() async {
+ await super.test_class_constructor_fieldFormal_optional_withDefault();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_class_field_const() async {
+ await super.test_class_field_const();
+ }
+
+ @override
test_class_setter_invalid_named_parameter() async {
var library = await checkLibrary('class C { void set x({a}) {} }');
checkElementText(library, r'''
@@ -149,6 +168,635 @@
test_const_constructor_inferred_args() =>
super.test_const_constructor_inferred_args();
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_finalField_hasConstConstructor() async {
+ await super.test_const_finalField_hasConstConstructor();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invalid_field_const() async {
+ await super.test_const_invalid_field_const();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invalid_intLiteral() async {
+ await super.test_const_invalid_intLiteral();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invalid_topLevel() async {
+ await super.test_const_invalid_topLevel();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_generic_named() async {
+ await super.test_const_invokeConstructor_generic_named();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_generic_named_imported() async {
+ await super.test_const_invokeConstructor_generic_named_imported();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_generic_named_imported_withPrefix() async {
+ return super
+ .test_const_invokeConstructor_generic_named_imported_withPrefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_generic_noTypeArguments() async {
+ await super.test_const_invokeConstructor_generic_noTypeArguments();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_generic_unnamed() async {
+ await super.test_const_invokeConstructor_generic_unnamed();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_generic_unnamed_imported() async {
+ await super.test_const_invokeConstructor_generic_unnamed_imported();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_generic_unnamed_imported_withPrefix() async {
+ return super
+ .test_const_invokeConstructor_generic_unnamed_imported_withPrefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_named() async {
+ await super.test_const_invokeConstructor_named();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_named_imported() async {
+ await super.test_const_invokeConstructor_named_imported();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_named_imported_withPrefix() async {
+ await super.test_const_invokeConstructor_named_imported_withPrefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_named_unresolved() async {
+ await super.test_const_invokeConstructor_named_unresolved();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_named_unresolved2() async {
+ await super.test_const_invokeConstructor_named_unresolved2();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_named_unresolved3() async {
+ await super.test_const_invokeConstructor_named_unresolved3();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_named_unresolved4() async {
+ await super.test_const_invokeConstructor_named_unresolved4();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_named_unresolved5() async {
+ await super.test_const_invokeConstructor_named_unresolved5();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_named_unresolved6() async {
+ await super.test_const_invokeConstructor_named_unresolved6();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_unnamed() async {
+ await super.test_const_invokeConstructor_unnamed();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_unnamed_imported() async {
+ await super.test_const_invokeConstructor_unnamed_imported();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_unnamed_imported_withPrefix() async {
+ await super.test_const_invokeConstructor_unnamed_imported_withPrefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_unnamed_unresolved() async {
+ await super.test_const_invokeConstructor_unnamed_unresolved();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_unnamed_unresolved2() async {
+ await super.test_const_invokeConstructor_unnamed_unresolved2();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_invokeConstructor_unnamed_unresolved3() async {
+ await super.test_const_invokeConstructor_unnamed_unresolved3();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_length_ofClassConstField() async {
+ await super.test_const_length_ofClassConstField();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_length_ofClassConstField_imported() async {
+ await super.test_const_length_ofClassConstField_imported();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_length_ofClassConstField_imported_withPrefix() async {
+ await super.test_const_length_ofClassConstField_imported_withPrefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_length_ofStringLiteral() async {
+ await super.test_const_length_ofStringLiteral();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_length_ofTopLevelVariable() async {
+ await super.test_const_length_ofTopLevelVariable();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_length_ofTopLevelVariable_imported() async {
+ await super.test_const_length_ofTopLevelVariable_imported();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_length_ofTopLevelVariable_imported_withPrefix() async {
+ await super.test_const_length_ofTopLevelVariable_imported_withPrefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_length_staticMethod() async {
+ await super.test_const_length_staticMethod();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_list_inferredType() async {
+ await super.test_const_list_inferredType();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_map_inferredType() async {
+ await super.test_const_map_inferredType();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_parameterDefaultValue_initializingFormal_functionTyped() async {
+ return super
+ .test_const_parameterDefaultValue_initializingFormal_functionTyped();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_parameterDefaultValue_initializingFormal_named() async {
+ await super.test_const_parameterDefaultValue_initializingFormal_named();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_parameterDefaultValue_initializingFormal_positional() async {
+ return super
+ .test_const_parameterDefaultValue_initializingFormal_positional();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_parameterDefaultValue_normal() async {
+ await super.test_const_parameterDefaultValue_normal();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_staticField() async {
+ await super.test_const_reference_staticField();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_staticField_imported() async {
+ await super.test_const_reference_staticField_imported();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_staticField_imported_withPrefix() async {
+ await super.test_const_reference_staticField_imported_withPrefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_staticMethod() async {
+ await super.test_const_reference_staticMethod();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_staticMethod_imported() async {
+ await super.test_const_reference_staticMethod_imported();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_staticMethod_imported_withPrefix() async {
+ await super.test_const_reference_staticMethod_imported_withPrefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_topLevelFunction() async {
+ await super.test_const_reference_topLevelFunction();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_topLevelFunction_generic() async {
+ await super.test_const_reference_topLevelFunction_generic();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_topLevelFunction_imported() async {
+ await super.test_const_reference_topLevelFunction_imported();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_topLevelFunction_imported_withPrefix() async {
+ await super.test_const_reference_topLevelFunction_imported_withPrefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_topLevelVariable() async {
+ await super.test_const_reference_topLevelVariable();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_topLevelVariable_imported() async {
+ await super.test_const_reference_topLevelVariable_imported();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_topLevelVariable_imported_withPrefix() async {
+ await super.test_const_reference_topLevelVariable_imported_withPrefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_type() async {
+ await super.test_const_reference_type();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_type_imported() async {
+ await super.test_const_reference_type_imported();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_type_imported_withPrefix() async {
+ await super.test_const_reference_type_imported_withPrefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_unresolved_prefix0() async {
+ await super.test_const_reference_unresolved_prefix0();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_unresolved_prefix1() async {
+ await super.test_const_reference_unresolved_prefix1();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_reference_unresolved_prefix2() async {
+ await super.test_const_reference_unresolved_prefix2();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_binary() async {
+ await super.test_const_topLevel_binary();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_conditional() async {
+ await super.test_const_topLevel_conditional();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_identical() async {
+ await super.test_const_topLevel_identical();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_ifNull() async {
+ await super.test_const_topLevel_ifNull();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_literal() async {
+ await super.test_const_topLevel_literal();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_parenthesis() async {
+ await super.test_const_topLevel_parenthesis();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_prefix() async {
+ await super.test_const_topLevel_prefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_super() async {
+ await super.test_const_topLevel_super();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_this() async {
+ await super.test_const_topLevel_this();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_typedList() async {
+ await super.test_const_topLevel_typedList();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_typedList_imported() async {
+ await super.test_const_topLevel_typedList_imported();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_typedList_importedWithPrefix() async {
+ await super.test_const_topLevel_typedList_importedWithPrefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_typedList_typedefArgument() async {
+ await super.test_const_topLevel_typedList_typedefArgument();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_typedMap() async {
+ await super.test_const_topLevel_typedMap();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_untypedList() async {
+ await super.test_const_topLevel_untypedList();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_const_topLevel_untypedMap() async {
+ await super.test_const_topLevel_untypedMap();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constExpr_pushReference_field_simpleIdentifier() async {
+ await super.test_constExpr_pushReference_field_simpleIdentifier();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constExpr_pushReference_staticMethod_simpleIdentifier() async {
+ await super.test_constExpr_pushReference_staticMethod_simpleIdentifier();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_initializers_assertInvocation() async {
+ await super.test_constructor_initializers_assertInvocation();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_initializers_assertInvocation_message() async {
+ await super.test_constructor_initializers_assertInvocation_message();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_initializers_field() async {
+ await super.test_constructor_initializers_field();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_initializers_field_notConst() async {
+ await super.test_constructor_initializers_field_notConst();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_initializers_field_withParameter() async {
+ await super.test_constructor_initializers_field_withParameter();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_initializers_superInvocation_named() async {
+ await super.test_constructor_initializers_superInvocation_named();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_initializers_superInvocation_named_underscore() async {
+ return super
+ .test_constructor_initializers_superInvocation_named_underscore();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_initializers_superInvocation_namedExpression() async {
+ return super
+ .test_constructor_initializers_superInvocation_namedExpression();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_initializers_superInvocation_unnamed() async {
+ await super.test_constructor_initializers_superInvocation_unnamed();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_initializers_thisInvocation_named() async {
+ await super.test_constructor_initializers_thisInvocation_named();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_initializers_thisInvocation_namedExpression() async {
+ await super.test_constructor_initializers_thisInvocation_namedExpression();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_initializers_thisInvocation_unnamed() async {
+ await super.test_constructor_initializers_thisInvocation_unnamed();
+ }
+
@failingTest
@FastaProblem('https://github.com/dart-lang/sdk/issues/30258')
test_constructor_redirected_factory_named_generic() async {
@@ -185,6 +833,83 @@
await super.test_constructor_redirected_factory_unnamed_prefixed_generic();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_redirected_thisInvocation_named() async {
+ await super.test_constructor_redirected_thisInvocation_named();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_redirected_thisInvocation_named_generic() async {
+ await super.test_constructor_redirected_thisInvocation_named_generic();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_redirected_thisInvocation_unnamed() async {
+ await super.test_constructor_redirected_thisInvocation_unnamed();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_redirected_thisInvocation_unnamed_generic() async {
+ await super.test_constructor_redirected_thisInvocation_unnamed_generic();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_constructor_withCycles_const() async {
+ await super.test_constructor_withCycles_const();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_defaultValue_refersToGenericClass_constructor() async {
+ await super.test_defaultValue_refersToGenericClass_constructor();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_defaultValue_refersToGenericClass_constructor2() async {
+ await super.test_defaultValue_refersToGenericClass_constructor2();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_defaultValue_refersToGenericClass_functionG() async {
+ await super.test_defaultValue_refersToGenericClass_functionG();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_defaultValue_refersToGenericClass_methodG() async {
+ await super.test_defaultValue_refersToGenericClass_methodG();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_defaultValue_refersToGenericClass_methodG_classG() async {
+ await super.test_defaultValue_refersToGenericClass_methodG_classG();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_defaultValue_refersToGenericClass_methodNG() async {
+ await super.test_defaultValue_refersToGenericClass_methodNG();
+ }
+
@failingTest
@notForDart2
test_export_configurations_useFirst() async {
@@ -203,6 +928,27 @@
await super.test_exportImport_configurations_useFirst();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_field_propagatedType_const_noDep() async {
+ await super.test_field_propagatedType_const_noDep();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_function_async() async {
+ await super.test_function_async();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_function_asyncStar() async {
+ await super.test_function_asyncStar();
+ }
+
@failingTest
@override
test_futureOr() async {
@@ -255,6 +1001,20 @@
@override
@failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_infer_generic_typedef_simple() async {
+ await super.test_infer_generic_typedef_simple();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_instantiateToBounds_functionTypeAlias_simple() async {
+ await super.test_instantiateToBounds_functionTypeAlias_simple();
+ }
+
+ @override
+ @failingTest
test_invalid_annotation_prefixed_constructor() {
return super.test_invalid_annotation_prefixed_constructor();
}
@@ -284,17 +1044,130 @@
}
@failingTest
- @FastaProblem('https://github.com/dart-lang/sdk/issues/30267')
- test_invalid_setterParameter_fieldFormalParameter() async {
- await super.test_invalid_setterParameter_fieldFormalParameter();
- }
-
- @failingTest
@FastaProblem('https://github.com/dart-lang/sdk/issues/30725')
test_invalidUri_part_emptyUri() async {
await super.test_invalidUri_part_emptyUri();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_invalidUris() async {
+ await super.test_invalidUris();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_member_function_async() async {
+ await super.test_member_function_async();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_member_function_asyncStar() async {
+ await super.test_member_function_asyncStar();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_member_function_syncStar() async {
+ await super.test_member_function_syncStar();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_classDeclaration() async {
+ await super.test_metadata_classDeclaration();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_classTypeAlias() async {
+ await super.test_metadata_classTypeAlias();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_constructor_call_named() async {
+ await super.test_metadata_constructor_call_named();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_constructor_call_named_prefixed() async {
+ await super.test_metadata_constructor_call_named_prefixed();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_constructor_call_unnamed() async {
+ await super.test_metadata_constructor_call_unnamed();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_constructor_call_unnamed_prefixed() async {
+ await super.test_metadata_constructor_call_unnamed_prefixed();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_constructor_call_with_args() async {
+ await super.test_metadata_constructor_call_with_args();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_constructorDeclaration_named() async {
+ await super.test_metadata_constructorDeclaration_named();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_constructorDeclaration_unnamed() async {
+ await super.test_metadata_constructorDeclaration_unnamed();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_enumConstantDeclaration() async {
+ await super.test_metadata_enumConstantDeclaration();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_enumDeclaration() async {
+ await super.test_metadata_enumDeclaration();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_exportDirective() async {
+ await super.test_metadata_exportDirective();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_fieldDeclaration() async {
+ await super.test_metadata_fieldDeclaration();
+ }
+
@failingTest
@FastaProblem('https://github.com/dart-lang/sdk/issues/28434')
test_metadata_fieldFormalParameter() async {
@@ -307,6 +1180,34 @@
await super.test_metadata_fieldFormalParameter_withDefault();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_functionDeclaration_function() async {
+ await super.test_metadata_functionDeclaration_function();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_functionDeclaration_getter() async {
+ await super.test_metadata_functionDeclaration_getter();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_functionDeclaration_setter() async {
+ await super.test_metadata_functionDeclaration_setter();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_functionTypeAlias() async {
+ await super.test_metadata_functionTypeAlias();
+ }
+
@failingTest
@FastaProblem('https://github.com/dart-lang/sdk/issues/28434')
test_metadata_functionTypedFormalParameter() async {
@@ -319,6 +1220,62 @@
await super.test_metadata_functionTypedFormalParameter_withDefault();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_importDirective() async {
+ await super.test_metadata_importDirective();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_invalid_classDeclaration() async {
+ await super.test_metadata_invalid_classDeclaration();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_libraryDirective() async {
+ await super.test_metadata_libraryDirective();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_methodDeclaration_getter() async {
+ await super.test_metadata_methodDeclaration_getter();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_methodDeclaration_method() async {
+ await super.test_metadata_methodDeclaration_method();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_methodDeclaration_setter() async {
+ await super.test_metadata_methodDeclaration_setter();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_partDirective() async {
+ await super.test_metadata_partDirective();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_prefixed_variable() async {
+ await super.test_metadata_prefixed_variable();
+ }
+
@failingTest
@FastaProblem('https://github.com/dart-lang/sdk/issues/28434')
test_metadata_simpleFormalParameter() async {
@@ -331,6 +1288,41 @@
await super.test_metadata_simpleFormalParameter_withDefault();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_topLevelVariableDeclaration() async {
+ await super.test_metadata_topLevelVariableDeclaration();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_typeParameter_ofClass() async {
+ await super.test_metadata_typeParameter_ofClass();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_typeParameter_ofClassTypeAlias() async {
+ await super.test_metadata_typeParameter_ofClassTypeAlias();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_typeParameter_ofFunction() async {
+ await super.test_metadata_typeParameter_ofFunction();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_metadata_typeParameter_ofTypedef() async {
+ await super.test_metadata_typeParameter_ofTypedef();
+ }
+
@failingTest
@notForDart2
test_parameter_checked() async {
@@ -345,6 +1337,55 @@
await super.test_parameter_checked_inherited();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_parameterTypeNotInferred_constructor() async {
+ await super.test_parameterTypeNotInferred_constructor();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_parameterTypeNotInferred_initializingFormal() async {
+ await super.test_parameterTypeNotInferred_initializingFormal();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_parameterTypeNotInferred_staticMethod() async {
+ await super.test_parameterTypeNotInferred_staticMethod();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_parameterTypeNotInferred_topLevelFunction() async {
+ await super.test_parameterTypeNotInferred_topLevelFunction();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_setter_inferred_type_conflictingInheritance() async {
+ await super.test_setter_inferred_type_conflictingInheritance();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_type_reference_to_typedef_with_type_arguments() async {
+ await super.test_type_reference_to_typedef_with_type_arguments();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_type_reference_to_typedef_with_type_arguments_implicit() async {
+ await super.test_type_reference_to_typedef_with_type_arguments_implicit();
+ }
+
@failingTest
@FastaProblem('https://github.com/dart-lang/sdk/issues/31711')
test_typedef_generic_asFieldType() async {
@@ -359,16 +1400,6 @@
}
@failingTest
- test_typedef_type_parameters_bound_recursive() async {
- await super.test_typedef_type_parameters_bound_recursive();
- }
-
- @failingTest
- test_typedef_type_parameters_bound_recursive2() async {
- await super.test_typedef_type_parameters_bound_recursive2();
- }
-
- @failingTest
@FastaProblem('https://github.com/dart-lang/sdk/issues/30267')
test_unresolved_annotation_instanceCreation_argument_super() async {
await super.test_unresolved_annotation_instanceCreation_argument_super();
@@ -376,6 +1407,28 @@
@override
@failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_unresolved_annotation_instanceCreation_argument_this() async {
+ await super.test_unresolved_annotation_instanceCreation_argument_this();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_unresolved_annotation_namedConstructorCall_noClass() async {
+ await super.test_unresolved_annotation_namedConstructorCall_noClass();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_unresolved_annotation_namedConstructorCall_noConstructor() async {
+ return super
+ .test_unresolved_annotation_namedConstructorCall_noConstructor();
+ }
+
+ @override
+ @failingTest
test_unresolved_annotation_prefixedIdentifier_badPrefix() {
return super.test_unresolved_annotation_prefixedIdentifier_badPrefix();
}
@@ -388,10 +1441,71 @@
@override
@failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_unresolved_annotation_prefixedNamedConstructorCall_badPrefix() async {
+ return super
+ .test_unresolved_annotation_prefixedNamedConstructorCall_badPrefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_unresolved_annotation_prefixedNamedConstructorCall_noClass() async {
+ return super
+ .test_unresolved_annotation_prefixedNamedConstructorCall_noClass();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_unresolved_annotation_prefixedNamedConstructorCall_noConstructor() async {
+ return super
+ .test_unresolved_annotation_prefixedNamedConstructorCall_noConstructor();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_unresolved_annotation_prefixedUnnamedConstructorCall_badPrefix() async {
+ return super
+ .test_unresolved_annotation_prefixedUnnamedConstructorCall_badPrefix();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_unresolved_annotation_prefixedUnnamedConstructorCall_noClass() async {
+ return super
+ .test_unresolved_annotation_prefixedUnnamedConstructorCall_noClass();
+ }
+
+ @override
+ @failingTest
test_unresolved_annotation_simpleIdentifier() {
return super.test_unresolved_annotation_simpleIdentifier();
}
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_unresolved_annotation_unnamedConstructorCall_noClass() async {
+ await super.test_unresolved_annotation_unnamedConstructorCall_noClass();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_variable_const() async {
+ await super.test_variable_const();
+ }
+
+ @override
+ @failingTest
+ @FastaProblem('https://github.com/dart-lang/sdk/issues/33567')
+ test_variable_propagatedType_const_noDep() async {
+ await super.test_variable_propagatedType_const_noDep();
+ }
+
Future<KernelResynthesizer> _createResynthesizer(Uri testUri) async {
var logger = new PerformanceLog(null);
var byteStore = new MemoryByteStore();
@@ -415,7 +1529,7 @@
fsState,
resourceProvider.pathContext);
- LibraryCompilationResult libraryResult = await compiler.compile(testUri);
+ LibraryOutlineResult libraryResult = await compiler.getOutline(testUri);
// Remember Kernel libraries produced by the compiler.
var libraryMap = <String, kernel.Library>{};
diff --git a/pkg/analyzer/tool/analyzer_cfe_progress.dart b/pkg/analyzer/tool/analyzer_cfe_progress.dart
new file mode 100644
index 0000000..27577db
--- /dev/null
+++ b/pkg/analyzer/tool/analyzer_cfe_progress.dart
@@ -0,0 +1,122 @@
+// Copyright (c) 2018, 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.
+
+import 'dart:io' as io;
+
+import 'package:analyzer/dart/analysis/context_builder.dart';
+import 'package:analyzer/dart/analysis/context_locator.dart';
+import 'package:analyzer/dart/analysis/context_root.dart';
+import 'package:analyzer/dart/analysis/results.dart';
+import 'package:analyzer/dart/analysis/session.dart';
+import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/file_system/file_system.dart';
+import 'package:analyzer/file_system/physical_file_system.dart';
+import 'package:path/path.dart' as path;
+
+// TODO(devoncarew): Convert the commented out code below to a --verbose option,
+// emitting failing tests in a markdown ready format?
+
+/// Count failing Analyzer CFE integration tests.
+///
+/// We look for classes ending in *Test_UseCFE or *Test_Kernel with test
+/// methods that are marked with @failingTest annotations.
+///
+/// In addition, we count the test exclusions from pkg/pkg.status related to
+/// using Fasta with the Analyzer.
+void main() {
+ if (!io.FileSystemEntity.isDirectorySync('pkg')) {
+ io.stderr
+ .writeln('This tool should be run from the top level sdk directory.');
+ io.exit(1);
+ }
+
+ final List<String> analysisPaths = [
+ 'pkg/analysis_server',
+ 'pkg/analyzer_cli',
+ 'pkg/analyzer_plugin',
+ 'pkg/analyzer',
+ ];
+
+ final ResourceProvider resourceProvider = PhysicalResourceProvider.INSTANCE;
+ ContextLocator locator =
+ new ContextLocator(resourceProvider: resourceProvider);
+ List<ContextRoot> contextRoots =
+ locator.locateRoots(includedPaths: analysisPaths);
+ ContextBuilder builder =
+ new ContextBuilder(resourceProvider: resourceProvider);
+
+ for (ContextRoot contextRoot in contextRoots) {
+ if (!analysisPaths
+ .any((analysisPath) => contextRoot.root.path.endsWith(analysisPath))) {
+ continue;
+ }
+
+ AnalysisSession analysisSession =
+ builder.createContext(contextRoot: contextRoot).currentSession;
+ print('\nCFE tests for ${path.relative(contextRoot.root.path)}:');
+
+ int totalFailingCount = 0;
+
+ for (String analyzedPath in contextRoot.analyzedFiles()) {
+ if (!analyzedPath.endsWith('_test.dart')) {
+ continue;
+ }
+
+ ParseResult result = analysisSession.getParsedAstSync(analyzedPath);
+ CompilationUnit unit = result.unit;
+
+ for (ClassDeclaration member
+ in unit.declarations.where((member) => member is ClassDeclaration)) {
+ String className = member.name.toString();
+ if (!className.endsWith('Test_UseCFE') &&
+ !className.endsWith('Test_Kernel')) {
+ continue;
+ }
+
+ int failingCount = 0;
+
+ for (MethodDeclaration method
+ in member.members.where((member) => member is MethodDeclaration)) {
+ String methodName = method.name.toString();
+ if (!methodName.startsWith('test_')) {
+ continue;
+ }
+
+ if (method.metadata.any((Annotation annotation) =>
+ annotation.name.toString() == 'failingTest')) {
+ failingCount++;
+ }
+ }
+
+ totalFailingCount += failingCount;
+
+ //if (failingCount > 0) {
+ // print(' ${member.name}, $failingCount failing tests');
+ //}
+ }
+ }
+
+ print(' $totalFailingCount failing tests');
+ }
+
+ // Also count the Fasta '-DuseFastaParser=true' tests.
+ print('\nuseFastaParser=true failures from pkg/pkg.status');
+
+ io.File file = new io.File('pkg/pkg.status');
+ List<String> lines = file.readAsLinesSync();
+ lines = lines
+ .where((line) => line.trim().isNotEmpty && !line.trim().startsWith('#'))
+ .toList();
+
+ int index = lines
+ .indexOf(r'[ $builder_tag == analyzer_use_fasta && $runtime == vm ]');
+ if (index == -1) {
+ print('error parsing ${file.path}');
+ }
+
+ lines = lines.sublist(index + 1);
+ lines = lines.sublist(0, lines.indexWhere((line) => line.startsWith('[')));
+
+ print(' ${lines.length} failing tests');
+}
diff --git a/pkg/analyzer_cli/test/driver_test.dart b/pkg/analyzer_cli/test/driver_test.dart
index 606e0c3..fa3df1e 100644
--- a/pkg/analyzer_cli/test/driver_test.dart
+++ b/pkg/analyzer_cli/test/driver_test.dart
@@ -659,13 +659,6 @@
class ExitCodesTest_PreviewDart2 extends ExitCodesTest {
@override
bool get usePreviewDart2 => true;
-
- @override
- @failingTest
- test_fatalErrors() {
- // TODO(devoncarew): This test times out when used with @failingTest.
- return new Future.error('failing test');
- }
}
@reflectiveTest
@@ -675,64 +668,7 @@
@override
@failingTest
- test_enableAssertInitializer() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_fatalErrors() {
- // TODO(devoncarew): This test times out when used with @failingTest.
- return new Future.error('failing test');
- }
-
- @override
- @failingTest
- test_fatalHints() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_fatalWarnings() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_missingOptionsFile() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_notFatalHints() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_notFatalWarnings() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_partFile() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_partFile_extra() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_partFile_reversed() {
- fail('Test crashes CFE');
- }
+ test_fatalWarnings() => callFailingTest(super.test_fatalWarnings);
}
@reflectiveTest
@@ -841,48 +777,6 @@
class LinterTest_UseCFE extends LinterTest {
@override
bool get useCFE => true;
-
- @override
- @failingTest
- test_defaultLints_generatedLints() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_defaultLints_getsDefaultLints() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_lintsInOptions_generatedLints() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_lintsInOptions_getAnalysisOptions() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_noLints_lintsDisabled() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_noLints_noGeneratedWarnings() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_noLints_noRegisteredLints() {
- fail('Test times out');
- }
}
@reflectiveTest
@@ -1099,75 +993,45 @@
@override
@failingTest
- test_analysisOptions_excludes() {
- fail('Test times out');
- }
+ test_analysisOptions_excludes() =>
+ callFailingTest(super.test_analysisOptions_excludes);
@override
@failingTest
- test_analysisOptions_excludesRelativeToAnalysisOptions_explicit() {
- fail('Test times out');
- }
+ test_analysisOptions_excludesRelativeToAnalysisOptions_explicit() =>
+ callFailingTest(super
+ .test_analysisOptions_excludesRelativeToAnalysisOptions_explicit);
@override
@failingTest
- test_analysisOptions_excludesRelativeToAnalysisOptions_inferred() {
- fail('Test times out');
- }
+ test_analysisOptions_excludesRelativeToAnalysisOptions_inferred() =>
+ callFailingTest(super
+ .test_analysisOptions_excludesRelativeToAnalysisOptions_inferred);
@override
@failingTest
- test_analyzeFilesInDifferentContexts() {
- fail('Test times out');
- }
+ test_basic_filters() => callFailingTest(super.test_basic_filters);
@override
@failingTest
- test_basic_filters() {
- fail('Test times out');
- }
+ test_basic_language() => callFailingTest(super.test_basic_language);
@override
@failingTest
- test_basic_language() {
- fail('Test times out');
- }
+ test_basic_strongMode() => callFailingTest(super.test_basic_strongMode);
@override
@failingTest
- test_basic_strongMode() {
- fail('Test times out');
- }
+ test_includeDirective() => callFailingTest(super.test_includeDirective);
@override
@failingTest
- test_includeDirective() {
- fail('Test times out');
- }
+ test_previewDart2() => callFailingTest(super.test_previewDart2);
@override
@failingTest
- test_previewDart2() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_strongSdk() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_todo() {
- fail('Test times out');
- }
-
- @override
- @failingTest
- test_withFlags_overrideFatalWarning() {
- fail('Test times out');
- }
+ test_withFlags_overrideFatalWarning() =>
+ callFailingTest(super.test_withFlags_overrideFatalWarning);
}
class TestSource implements Source {
@@ -1176,3 +1040,32 @@
@override
noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation);
}
+
+typedef dynamic NoArgFunction();
+
+/**
+ * Call a test that we think will fail.
+ *
+ * Ensure that we return any thrown exception correctly (avoiding the
+ * package:test zone error handler).
+ */
+callFailingTest(NoArgFunction expectedFailingTestFn) {
+ final Completer completer = new Completer();
+
+ try {
+ runZoned(
+ () async => await expectedFailingTestFn(),
+ onError: (error) {
+ completer.completeError(error);
+ },
+ ).then((result) {
+ completer.complete(result);
+ }).catchError((error) {
+ completer.completeError(error);
+ });
+ } catch (error) {
+ completer.completeError(error);
+ }
+
+ return completer.future;
+}
diff --git a/pkg/build_integration/pubspec.yaml b/pkg/build_integration/pubspec.yaml
index cb58f97..a8c5bef 100644
--- a/pkg/build_integration/pubspec.yaml
+++ b/pkg/build_integration/pubspec.yaml
@@ -1,9 +1,9 @@
name: build_integration
-version: 0.0.1
-author: Dart Team <misc@dartlang.org>
description: >
Libraries for integrating Dart tools with build systems like bazel
and build_runner.
-homepage: https://github.com/dart-lang/sdk/tree/master/pkg/build_integration
+# This package is not intended to be published - yet
+publish_to: none
+
dependencies:
front_end: ^0.1.0
diff --git a/pkg/compiler/lib/compiler.dart b/pkg/compiler/lib/compiler.dart
index 32c8b43..671f426 100644
--- a/pkg/compiler/lib/compiler.dart
+++ b/pkg/compiler/lib/compiler.dart
@@ -109,7 +109,7 @@
CompilerInputProvider inputProvider, DiagnosticHandler handler,
[List<String> options = const [],
CompilerOutputProvider outputProvider,
- Map<String, dynamic> environment = const {},
+ Map<String, String> environment = const {},
Uri packageConfig,
PackagesDiscoveryProvider packagesDiscoveryProvider]) {
CompilerOptions compilerOptions =
diff --git a/pkg/compiler/lib/src/apiimpl.dart b/pkg/compiler/lib/src/apiimpl.dart
index 4fcea9f..a855925 100644
--- a/pkg/compiler/lib/src/apiimpl.dart
+++ b/pkg/compiler/lib/src/apiimpl.dart
@@ -157,6 +157,10 @@
});
}
+ String _formatMs(int ms) {
+ return (ms / 1000).toStringAsFixed(3) + 's';
+ }
+
void computeTimings(Duration setupDuration, StringBuffer timings) {
timings.writeln("Timings:");
Duration totalDuration = measurer.wallClock.elapsed;
@@ -167,13 +171,13 @@
Duration duration = task.duration;
if (duration != Duration.zero) {
cumulatedDuration += duration;
- timings.writeln(' $running${task.name} took'
- ' ${duration.inMilliseconds}msec');
+ timings.writeln(' $running${task.name}:'
+ ' ${_formatMs(duration.inMilliseconds)}');
for (String subtask in task.subtasks) {
int subtime = task.getSubtaskTime(subtask);
String running = task.getSubtaskIsRunning(subtask) ? "*" : "";
timings.writeln(
- ' $running${task.name} > $subtask took ${subtime}msec');
+ ' $running${task.name} > $subtask: ${_formatMs(subtime)}');
}
}
}
@@ -181,10 +185,11 @@
totalDuration - cumulatedDuration - setupDuration - asyncDuration;
double percent =
unaccountedDuration.inMilliseconds * 100 / totalDuration.inMilliseconds;
- timings.write(' Total compile-time ${totalDuration.inMilliseconds}msec;'
- ' setup ${setupDuration.inMilliseconds}msec;'
- ' async ${asyncDuration.inMilliseconds}msec;'
- ' unaccounted ${unaccountedDuration.inMilliseconds}msec'
+ timings.write(
+ ' Total compile-time ${_formatMs(totalDuration.inMilliseconds)};'
+ ' setup ${_formatMs(setupDuration.inMilliseconds)};'
+ ' async ${_formatMs(asyncDuration.inMilliseconds)};'
+ ' unaccounted ${_formatMs(unaccountedDuration.inMilliseconds)}'
' (${percent.toStringAsFixed(2)}%)');
}
diff --git a/pkg/compiler/lib/src/frontend_strategy.dart b/pkg/compiler/lib/src/frontend_strategy.dart
index f6b8293..45f1261 100644
--- a/pkg/compiler/lib/src/frontend_strategy.dart
+++ b/pkg/compiler/lib/src/frontend_strategy.dart
@@ -23,7 +23,7 @@
import 'library_loader.dart';
import 'native/enqueue.dart' show NativeResolutionEnqueuer;
import 'native/resolver.dart';
-import 'universe/class_hierarchy_builder.dart';
+import 'universe/class_hierarchy.dart';
import 'universe/world_builder.dart';
import 'universe/world_impact.dart';
diff --git a/pkg/compiler/lib/src/helpers/stats.dart b/pkg/compiler/lib/src/helpers/stats.dart
index c8f6c0da0..935ac8c 100644
--- a/pkg/compiler/lib/src/helpers/stats.dart
+++ b/pkg/compiler/lib/src/helpers/stats.dart
@@ -537,13 +537,13 @@
}
void recordFrequency(id, value, [example]) {
- Map<int, List> map = frequencyMaps.putIfAbsent(id, () => {});
+ Map<dynamic, List> map = frequencyMaps.putIfAbsent(id, () => {});
map.putIfAbsent(value, () => []);
map[value].add(example);
}
void recordFrequencies(id, Map<dynamic, Iterable> frequencyMap) {
- Map<int, List> map = frequencyMaps.putIfAbsent(id, () => {});
+ Map<dynamic, List> map = frequencyMaps.putIfAbsent(id, () => {});
frequencyMap.forEach((value, examples) {
map.putIfAbsent(value, () => []);
map[value].addAll(examples);
@@ -707,7 +707,7 @@
{int limit, Map dataMap, bool includeCount: true}) {
if (limit == 0) return;
- Map childData = {};
+ Map<String, dynamic> childData = {};
Iterable nonNullIterable = iterable.where((e) => e != null);
if (nonNullIterable.isEmpty && !includeCount) {
childData['name'] = title;
@@ -748,11 +748,11 @@
///
/// If [isValidKey] is provided, this is used to determine with a value of [map]
/// is a potential key of the inversion map.
-Map<dynamic, Set> inverseMap(Map map,
- {bool equals(key1, key2),
- int hashCode(key),
- bool isValidKey(potentialKey)}) {
- Map<dynamic, Set> result = new LinkedHashMap<dynamic, Set>(
+Map<V, Set<K>> inverseMap<K, V>(Map<K, V> map,
+ {bool equals(V key1, V key2),
+ int hashCode(V key),
+ bool isValidKey(V potentialKey)}) {
+ Map<V, Set<K>> result = new LinkedHashMap<V, Set<K>>(
equals: equals, hashCode: hashCode, isValidKey: isValidKey);
map.forEach((k, v) {
if (isValidKey == null || isValidKey(v)) {
@@ -767,11 +767,11 @@
/// the assumption that all keys are [Comparable].
/// Otherwise, the keys are sorted as string using their `toString`
/// representation.
-Map trySortMap(Map map) {
- Iterable iterable = map.keys.where((k) => k != null);
+Map<K, V> trySortMap<K, V>(Map<K, V> map) {
+ Iterable<K> iterable = map.keys.where((K k) => k != null);
if (iterable.isEmpty) return map;
var key = iterable.first;
- if (key is Comparable) {
+ if (key is Comparable<K>) {
return sortMap(map);
}
return sortMap(map, (a, b) => '$a'.compareTo('$b'));
@@ -779,10 +779,10 @@
/// Returns a new map in which the keys of [map] are sorted using [compare].
/// If [compare] is null, the keys must be [Comparable].
-Map sortMap(Map map, [int compare(a, b)]) {
- List keys = map.keys.toList();
+Map<K, V> sortMap<K, V>(Map<K, V> map, [int compare(K a, K b)]) {
+ List<K> keys = map.keys.toList();
keys.sort(compare);
- Map sortedMap = new Map();
- keys.forEach((k) => sortedMap[k] = map[k]);
+ Map<K, V> sortedMap = new Map<K, V>();
+ keys.forEach((K k) => sortedMap[k] = map[k]);
return sortedMap;
}
diff --git a/pkg/compiler/lib/src/inferrer/type_graph_dump.dart b/pkg/compiler/lib/src/inferrer/type_graph_dump.dart
index 52ff120..549c287 100644
--- a/pkg/compiler/lib/src/inferrer/type_graph_dump.dart
+++ b/pkg/compiler/lib/src/inferrer/type_graph_dump.dart
@@ -364,7 +364,8 @@
addNode(info, 'BoolLiteral\n${info.value}');
}
- void handleCall(CallSiteTypeInformation info, String text, Map inputs) {
+ void handleCall(CallSiteTypeInformation info, String text,
+ Map<String, TypeInformation> inputs) {
String sourceCode = shorten('${info.debugName}');
text = '$text\n$sourceCode';
if (info.arguments != null) {
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 644cfd2..7311eb2 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/flat_type_mask.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/flat_type_mask.dart
@@ -334,23 +334,50 @@
assert(TypeMask.assertIsNormalized(this, closedWorld));
assert(TypeMask.assertIsNormalized(other, closedWorld));
FlatTypeMask flatOther = other;
- if (isEmptyOrNull) {
- return flatOther.isNullable ? this : nonNullable();
- } else if (flatOther.isEmptyOrNull) {
- return isNullable ? flatOther : other.nonNullable();
- } else if (base == flatOther.base) {
- return intersectionSame(flatOther, closedWorld);
- } else if (closedWorld.isSubclassOf(flatOther.base, base)) {
- return intersectionStrictSubclass(flatOther, closedWorld);
- } else if (closedWorld.isSubclassOf(base, flatOther.base)) {
- return flatOther.intersectionStrictSubclass(this, closedWorld);
- } else if (closedWorld.isSubtypeOf(flatOther.base, base)) {
- return intersectionStrictSubtype(flatOther, closedWorld);
- } else if (closedWorld.isSubtypeOf(base, flatOther.base)) {
- return flatOther.intersectionStrictSubtype(this, closedWorld);
- } else {
- return intersectionDisjoint(flatOther, closedWorld);
+
+ ClassEntity otherBase = flatOther.base;
+
+ bool includeNull = isNullable && flatOther.isNullable;
+
+ TypeMask emptyOrNull() {
+ return includeNull
+ ? closedWorld.abstractValueDomain.nullType
+ : closedWorld.abstractValueDomain.emptyType;
}
+
+ if (isEmptyOrNull || flatOther.isEmptyOrNull) {
+ return emptyOrNull();
+ }
+
+ SubclassResult result = closedWorld.classHierarchy
+ .commonSubclasses(base, _classQuery, otherBase, flatOther._classQuery);
+
+ FlatTypeMask createSingle(ClassEntity cls) {
+ switch (result.query) {
+ case ClassQuery.EXACT:
+ return includeNull
+ ? new TypeMask.exact(cls, closedWorld)
+ : new TypeMask.nonNullExact(cls, closedWorld);
+ case ClassQuery.SUBCLASS:
+ return includeNull
+ ? new TypeMask.subclass(cls, closedWorld)
+ : new TypeMask.nonNullSubclass(cls, closedWorld);
+ case ClassQuery.SUBTYPE:
+ return includeNull
+ ? new TypeMask.subtype(cls, closedWorld)
+ : new TypeMask.nonNullSubtype(cls, closedWorld);
+ }
+ throw new UnsupportedError("Unexpected ClassQuery: ${result.query}.");
+ }
+
+ List<FlatTypeMask> masks =
+ result.classes.map<FlatTypeMask>(createSingle).toList();
+ if (masks.isEmpty) return emptyOrNull();
+ if (masks.length == 1) return masks.single;
+ if (masks.length > UnionTypeMask.MAX_UNION_LENGTH) {
+ return UnionTypeMask.flatten(masks, closedWorld);
+ }
+ return new UnionTypeMask._internal(masks);
}
bool isDisjoint(TypeMask other, JClosedWorld closedWorld) {
@@ -432,54 +459,6 @@
}
}
- TypeMask intersectionStrictSubtype(
- FlatTypeMask other, JClosedWorld closedWorld) {
- assert(base != other.base);
- assert(closedWorld.isSubtypeOf(other.base, base));
- if (!isSubtype) return intersectionHelper(other, closedWorld);
- // Only the other mask puts constraints on the intersection mask,
- // so base the combined flags on the other mask. Only if both
- // masks are nullable, will the result be nullable too.
- // The result is guaranteed to be normalized, as the other type
- // was normalized.
- int combined = other.flags & ((flags & 1) | ~1);
- if (other.flags == combined) {
- return other;
- } else {
- return new FlatTypeMask.normalized(other.base, combined, closedWorld);
- }
- }
-
- TypeMask intersectionDisjoint(FlatTypeMask other, JClosedWorld closedWorld) {
- assert(base != other.base);
- assert(!closedWorld.isSubtypeOf(base, other.base));
- assert(!closedWorld.isSubtypeOf(other.base, base));
- return intersectionHelper(other, closedWorld);
- }
-
- TypeMask intersectionHelper(FlatTypeMask other, JClosedWorld closedWorld) {
- assert(base != other.base);
- assert(!closedWorld.isSubclassOf(base, other.base));
- assert(!closedWorld.isSubclassOf(other.base, base));
- // If one of the masks are exact or if both of them are subclass
- // masks, then the intersection is empty.
- if (isExact || other.isExact) return intersectionEmpty(other);
- if (isSubclass && other.isSubclass) return intersectionEmpty(other);
- assert(isSubtype || other.isSubtype);
- int kind = (isSubclass || other.isSubclass) ? SUBCLASS : SUBTYPE;
- Iterable<ClassEntity> candidates = closedWorld.commonSubclasses(
- base, _classQuery, other.base, other._classQuery);
- if (candidates.isEmpty) return intersectionEmpty(other);
- // Run through the list of candidates and compute the union. The
- // result will only be nullable if both masks are nullable. We have
- // to normalize here, as we generate types based on new base classes.
- int combined = (kind << 1) | (flags & other.flags & 1);
- Iterable<TypeMask> masks = candidates.map((ClassEntity cls) {
- return new FlatTypeMask.normalized(cls, combined, closedWorld);
- });
- return UnionTypeMask.unionOf(masks, closedWorld);
- }
-
TypeMask intersectionEmpty(FlatTypeMask other) {
return isNullable && other.isNullable
? new TypeMask.empty()
diff --git a/pkg/compiler/lib/src/inferrer/typemasks/masks.dart b/pkg/compiler/lib/src/inferrer/typemasks/masks.dart
index 2b6ae66..23752a0 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/masks.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/masks.dart
@@ -9,12 +9,13 @@
import '../../constants/values.dart' show ConstantValue, PrimitiveConstantValue;
import '../../elements/entities.dart';
import '../../types/abstract_value_domain.dart';
+import '../../universe/class_hierarchy.dart';
import '../../universe/selector.dart' show Selector;
import '../../universe/use.dart' show DynamicUse;
import '../../universe/world_builder.dart'
show UniverseSelectorConstraints, SelectorConstraintsStrategy;
import '../../util/util.dart';
-import '../../world.dart' show ClassQuery, JClosedWorld;
+import '../../world.dart' show JClosedWorld;
import '../type_graph_inferrer.dart' show TypeGraphInferrer;
import 'constants.dart';
diff --git a/pkg/compiler/lib/src/js_backend/backend.dart b/pkg/compiler/lib/src/js_backend/backend.dart
index 8b424b6..3b6fc65 100644
--- a/pkg/compiler/lib/src/js_backend/backend.dart
+++ b/pkg/compiler/lib/src/js_backend/backend.dart
@@ -38,7 +38,7 @@
import '../ssa/ssa.dart' show SsaFunctionCompiler;
import '../tracer.dart';
import '../universe/call_structure.dart' show CallStructure;
-import '../universe/class_hierarchy_builder.dart'
+import '../universe/class_hierarchy.dart'
show ClassHierarchyBuilder, ClassQueries;
import '../universe/selector.dart' show Selector;
import '../universe/use.dart' show StaticUse;
diff --git a/pkg/compiler/lib/src/js_backend/constant_emitter.dart b/pkg/compiler/lib/src/js_backend/constant_emitter.dart
index 7069820..0ce6141 100644
--- a/pkg/compiler/lib/src/js_backend/constant_emitter.dart
+++ b/pkg/compiler/lib/src/js_backend/constant_emitter.dart
@@ -13,6 +13,7 @@
import '../js_emitter/code_emitter_task.dart';
import '../options.dart';
import '../universe/world_builder.dart';
+import 'allocator_analysis.dart' show JAllocatorAnalysis;
import 'constant_system_javascript.dart';
import 'js_backend.dart';
import 'namer.dart';
@@ -40,6 +41,7 @@
final CodegenWorldBuilder _worldBuilder;
final RuntimeTypesNeed _rtiNeed;
final RuntimeTypesEncoder _rtiEncoder;
+ final JAllocatorAnalysis _allocatorAnalysis;
final Namer _namer;
final CodeEmitterTask _task;
final _ConstantReferenceGenerator constantReferenceGenerator;
@@ -56,6 +58,7 @@
this._worldBuilder,
this._rtiNeed,
this._rtiEncoder,
+ this._allocatorAnalysis,
this._namer,
this._task,
this.constantReferenceGenerator,
@@ -325,7 +328,9 @@
_emitter.constructorAccess(constant.type.element);
List<jsAst.Expression> fields = <jsAst.Expression>[];
_worldBuilder.forEachInstanceField(element, (_, FieldEntity field) {
- fields.add(constantReferenceGenerator(constant.fields[field]));
+ if (!_allocatorAnalysis.isInitializedInAllocator(field)) {
+ fields.add(constantReferenceGenerator(constant.fields[field]));
+ }
});
if (_rtiNeed.classNeedsTypeArguments(constant.type.element)) {
fields.add(_reifiedTypeArguments(constant, constant.type.typeArguments));
diff --git a/pkg/compiler/lib/src/js_backend/impact_transformer.dart b/pkg/compiler/lib/src/js_backend/impact_transformer.dart
index a438262..b7a388a 100644
--- a/pkg/compiler/lib/src/js_backend/impact_transformer.dart
+++ b/pkg/compiler/lib/src/js_backend/impact_transformer.dart
@@ -4,7 +4,7 @@
library js_backend.backend.impact_transformer;
-import '../universe/class_hierarchy_builder.dart' show ClassHierarchyBuilder;
+import '../universe/class_hierarchy.dart' show ClassHierarchyBuilder;
import '../common.dart';
import '../common_elements.dart';
diff --git a/pkg/compiler/lib/src/js_backend/runtime_types.dart b/pkg/compiler/lib/src/js_backend/runtime_types.dart
index a449b52..54863e5 100644
--- a/pkg/compiler/lib/src/js_backend/runtime_types.dart
+++ b/pkg/compiler/lib/src/js_backend/runtime_types.dart
@@ -13,10 +13,11 @@
import '../js/js.dart' show js;
import '../js_emitter/js_emitter.dart' show Emitter;
import '../options.dart';
+import '../universe/class_hierarchy.dart';
import '../universe/feature.dart';
import '../universe/selector.dart';
import '../universe/world_builder.dart';
-import '../world.dart' show ClassQuery, JClosedWorld, KClosedWorld;
+import '../world.dart' show JClosedWorld, KClosedWorld;
import 'backend_usage.dart';
import 'namer.dart';
import 'native_data.dart';
@@ -1469,7 +1470,8 @@
classesNeedingTypeArguments.add(cls);
// TODO(ngeoffray): This should use subclasses, not subtypes.
- closedWorld.forEachStrictSubtypeOf(cls, (ClassEntity sub) {
+ closedWorld.classHierarchy.forEachStrictSubtypeOf(cls,
+ (ClassEntity sub) {
potentiallyNeedTypeArguments(sub);
});
} else if (entity is FunctionEntity) {
@@ -1694,19 +1696,16 @@
impliedClass(runtimeTypeUse.argumentType);
// TODO(johnniwinther): Special case use of `this.runtimeType`.
- if (closedWorld.isSubtypeOf(receiverClass, argumentClass)) {
- addClass(receiverClass);
- } else if (closedWorld.isSubtypeOf(argumentClass, receiverClass)) {
- addClass(argumentClass);
+ SubclassResult result = closedWorld.classHierarchy.commonSubclasses(
+ receiverClass,
+ ClassQuery.SUBTYPE,
+ argumentClass,
+ ClassQuery.SUBTYPE);
+
+ for (ClassEntity cls in result.classes) {
+ addClass(cls);
+ if (neededOnAll) break;
}
- if (neededOnAll) break;
- // TODO(johnniwinther): Special case use of `this.runtimeType`.
- // TODO(johnniwinther): Rename [commonSubclasses] to something like
- // [strictCommonClasses] and support the non-strict case directly.
- // Since we do a subclassesOf
- classesDirectlyNeedingRuntimeType.addAll(
- closedWorld.commonSubclasses(receiverClass, ClassQuery.SUBTYPE,
- argumentClass, ClassQuery.SUBTYPE));
break;
case RuntimeTypeUseKind.unknown:
addClass(impliedClass(runtimeTypeUse.receiverType));
@@ -1717,15 +1716,17 @@
Set<ClassEntity> allClassesNeedingRuntimeType;
if (neededOnAll) {
neededOnFunctions = true;
- allClassesNeedingRuntimeType =
- closedWorld.subclassesOf(commonElements.objectClass).toSet();
+ allClassesNeedingRuntimeType = closedWorld.classHierarchy
+ .subclassesOf(commonElements.objectClass)
+ .toSet();
} else {
allClassesNeedingRuntimeType = new Set<ClassEntity>();
// TODO(johnniwinther): Support this operation directly in
// [ClosedWorld] using the [ClassSet]s.
for (ClassEntity cls in classesDirectlyNeedingRuntimeType) {
if (!allClassesNeedingRuntimeType.contains(cls)) {
- allClassesNeedingRuntimeType.addAll(closedWorld.subtypesOf(cls));
+ allClassesNeedingRuntimeType
+ .addAll(closedWorld.classHierarchy.subtypesOf(cls));
}
}
}
diff --git a/pkg/compiler/lib/src/js_emitter/full_emitter/emitter.dart b/pkg/compiler/lib/src/js_emitter/full_emitter/emitter.dart
index 407b49e..19692ba 100644
--- a/pkg/compiler/lib/src/js_emitter/full_emitter/emitter.dart
+++ b/pkg/compiler/lib/src/js_emitter/full_emitter/emitter.dart
@@ -166,6 +166,7 @@
compiler.codegenWorldBuilder,
_closedWorld.rtiNeed,
compiler.backend.rtiEncoder,
+ _closedWorld.allocatorAnalysis,
namer,
task,
this.constantReference,
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 edda727..46bce90 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
@@ -83,6 +83,7 @@
compiler.codegenWorldBuilder,
_closedWorld.rtiNeed,
compiler.backend.rtiEncoder,
+ _closedWorld.allocatorAnalysis,
namer,
task,
this.generateConstantReference,
diff --git a/pkg/compiler/lib/src/js_model/js_strategy.dart b/pkg/compiler/lib/src/js_model/js_strategy.dart
index 6b68731..1f4923a 100644
--- a/pkg/compiler/lib/src/js_model/js_strategy.dart
+++ b/pkg/compiler/lib/src/js_model/js_strategy.dart
@@ -289,10 +289,10 @@
});
}
- closedWorld
+ closedWorld.classHierarchy
.getClassHierarchyNode(closedWorld.commonElements.objectClass)
.forEachSubclass((ClassEntity cls) {
- convertClassSet(closedWorld.getClassSet(cls));
+ convertClassSet(closedWorld.classHierarchy.getClassSet(cls));
}, ClassHierarchyNode.ALL);
Set<MemberEntity> liveInstanceMembers =
diff --git a/pkg/compiler/lib/src/kernel/dart2js_target.dart b/pkg/compiler/lib/src/kernel/dart2js_target.dart
index 71a8c15..891f792 100644
--- a/pkg/compiler/lib/src/kernel/dart2js_target.dart
+++ b/pkg/compiler/lib/src/kernel/dart2js_target.dart
@@ -42,6 +42,9 @@
bool get nativeExtensionExpectsString => false;
@override
+ bool get errorOnUnexactWebIntLiterals => true;
+
+ @override
void performModularTransformationsOnLibraries(
CoreTypes coreTypes, ClassHierarchy hierarchy, List<ir.Library> libraries,
{void logger(String msg)}) {}
diff --git a/pkg/compiler/lib/src/kernel/element_map_impl.dart b/pkg/compiler/lib/src/kernel/element_map_impl.dart
index b2584d4..b3e5f49 100644
--- a/pkg/compiler/lib/src/kernel/element_map_impl.dart
+++ b/pkg/compiler/lib/src/kernel/element_map_impl.dart
@@ -43,7 +43,7 @@
import '../ordered_typeset.dart';
import '../ssa/kernel_impact.dart';
import '../ssa/type_builder.dart';
-import '../universe/class_hierarchy_builder.dart';
+import '../universe/class_hierarchy.dart';
import '../universe/class_set.dart';
import '../universe/selector.dart';
import '../universe/world_builder.dart';
@@ -439,11 +439,20 @@
}
List<DartType> parameterTypes = <DartType>[];
List<DartType> optionalParameterTypes = <DartType>[];
+
+ DartType getParameterType(ir.VariableDeclaration variable) {
+ if (variable.isCovariant || variable.isGenericCovariantImpl) {
+ // A covariant parameter has type `Object` in the method signature.
+ return commonElements.objectType;
+ }
+ return getDartType(variable.type);
+ }
+
for (ir.VariableDeclaration variable in node.positionalParameters) {
if (parameterTypes.length == node.requiredParameterCount) {
- optionalParameterTypes.add(getDartType(variable.type));
+ optionalParameterTypes.add(getParameterType(variable));
} else {
- parameterTypes.add(getDartType(variable.type));
+ parameterTypes.add(getParameterType(variable));
}
}
List<String> namedParameters = <String>[];
@@ -452,7 +461,7 @@
node.namedParameters.toList()..sort((a, b) => a.name.compareTo(b.name));
for (ir.VariableDeclaration variable in sortedNamedParameters) {
namedParameters.add(variable.name);
- namedParameterTypes.add(getDartType(variable.type));
+ namedParameterTypes.add(getParameterType(variable));
}
List<FunctionTypeVariable> typeVariables;
if (node.typeParameters.isNotEmpty && options.strongMode) {
@@ -2064,9 +2073,6 @@
final Map<ClassEntity, Set<ClassEntity>> typesImplementedBySubclasses;
- final Map<ClassEntity, ClassHierarchyNode> _classHierarchyNodes;
- final Map<ClassEntity, ClassSet> _classSets;
-
// TODO(johnniwinther): Can this be derived from [ClassSet]s?
final Set<ClassEntity> _implementedClasses;
@@ -2080,6 +2086,8 @@
final Iterable<MemberEntity> processedMembers;
+ final ClassHierarchy classHierarchy;
+
KClosedWorldImpl(this.elementMap,
{CompilerOptions options,
this.elementEnvironment,
@@ -2102,8 +2110,8 @@
Map<ClassEntity, ClassHierarchyNode> classHierarchyNodes,
Map<ClassEntity, ClassSet> classSets})
: _implementedClasses = implementedClasses,
- _classHierarchyNodes = classHierarchyNodes,
- _classSets = classSets {
+ classHierarchy = new ClassHierarchyImpl(
+ commonElements, classHierarchyNodes, classSets) {
computeRtiNeed(resolutionWorldBuilder, rtiNeedBuilder, options);
}
@@ -2111,152 +2119,6 @@
bool isImplemented(ClassEntity cls) {
return _implementedClasses.contains(cls);
}
-
- /// Returns [ClassHierarchyNode] for [cls] used to model the class hierarchies
- /// of known classes.
- ///
- /// This method is only provided for testing. For queries on classes, use the
- /// methods defined in [JClosedWorld].
- ClassHierarchyNode getClassHierarchyNode(ClassEntity cls) {
- return _classHierarchyNodes[cls];
- }
-
- /// Returns [ClassSet] for [cls] used to model the extends and implements
- /// relations of known classes.
- ///
- /// This method is only provided for testing. For queries on classes, use the
- /// methods defined in [JClosedWorld].
- ClassSet getClassSet(ClassEntity cls) {
- return _classSets[cls];
- }
-
- // TODO(johnniwinther): Share the methods based on [ClassSet] and
- // [ClassHierarchyNode] between KClosedWorld and JClosedWorld.
- /// Returns `true` if [x] is a subtype of [y], that is, if [x] implements an
- /// instance of [y].
- bool isSubtypeOf(ClassEntity x, ClassEntity y) {
- ClassSet classSet = _classSets[y];
- assert(classSet != null,
- failedAt(y, "No ClassSet for $y (${y.runtimeType}): ${_classSets}"));
- ClassHierarchyNode classHierarchyNode = _classHierarchyNodes[x];
- assert(classHierarchyNode != null,
- failedAt(x, "No ClassHierarchyNode for $x"));
- return classSet.hasSubtype(classHierarchyNode);
- }
-
- /// Returns an iterable over the directly instantiated that implement [cls]
- /// possibly including [cls] itself, if it is live.
- Iterable<ClassEntity> subtypesOf(ClassEntity cls) {
- ClassSet classSet = _classSets[cls];
- if (classSet == null) {
- return const <ClassEntity>[];
- } else {
- return classSet
- .subtypesByMask(ClassHierarchyNode.EXPLICITLY_INSTANTIATED);
- }
- }
-
- /// Returns an iterable over the directly instantiated classes that extend
- /// [cls] possibly including [cls] itself, if it is live.
- Iterable<ClassEntity> subclassesOf(ClassEntity cls) {
- ClassHierarchyNode hierarchy = _classHierarchyNodes[cls];
- if (hierarchy == null) return const <ClassEntity>[];
- return hierarchy
- .subclassesByMask(ClassHierarchyNode.EXPLICITLY_INSTANTIATED);
- }
-
- /// Returns an iterable over the directly instantiated that implement [cls]
- /// _not_ including [cls].
- Iterable<ClassEntity> strictSubtypesOf(ClassEntity cls) {
- ClassSet classSet = _classSets[cls];
- if (classSet == null) {
- return const <ClassEntity>[];
- } else {
- return classSet.subtypesByMask(ClassHierarchyNode.EXPLICITLY_INSTANTIATED,
- strict: true);
- }
- }
-
- Iterable<ClassEntity> getInterfaces(ClassEntity cls) {
- return elementMap._getInterfaces(cls).map((t) => t.element);
- }
-
- ClassEntity getSuperClass(ClassEntity cls) {
- return elementMap._getSuperType(cls)?.element;
- }
-
- /// Returns an iterable over the directly instantiated classes that extend
- /// [cls] _not_ including [cls] itself.
- Iterable<ClassEntity> strictSubclassesOf(ClassEntity cls) {
- ClassHierarchyNode subclasses = _classHierarchyNodes[cls];
- if (subclasses == null) return const <ClassEntity>[];
- return subclasses.subclassesByMask(
- ClassHierarchyNode.EXPLICITLY_INSTANTIATED,
- strict: true);
- }
-
- Set<ClassEntity> _commonContainedClasses(ClassEntity cls1, ClassQuery query1,
- ClassEntity cls2, ClassQuery query2) {
- Iterable<ClassEntity> xSubset = _containedSubset(cls1, query1);
- if (xSubset == null) return null;
- Iterable<ClassEntity> ySubset = _containedSubset(cls2, query2);
- if (ySubset == null) return null;
- return xSubset.toSet().intersection(ySubset.toSet());
- }
-
- Iterable<ClassEntity> _containedSubset(ClassEntity cls, ClassQuery query) {
- switch (query) {
- case ClassQuery.EXACT:
- return null;
- case ClassQuery.SUBCLASS:
- return strictSubclassesOf(cls);
- case ClassQuery.SUBTYPE:
- return strictSubtypesOf(cls);
- }
- throw new ArgumentError('Unexpected query: $query.');
- }
-
- Iterable<ClassEntity> commonSubclasses(ClassEntity cls1, ClassQuery query1,
- ClassEntity cls2, ClassQuery query2) {
- // TODO(johnniwinther): Use [ClassSet] to compute this.
- // Compute the set of classes that are contained in both class subsets.
- Set<ClassEntity> common =
- _commonContainedClasses(cls1, query1, cls2, query2);
- if (common == null || common.isEmpty) return const <ClassEntity>[];
- // Narrow down the candidates by only looking at common classes
- // that do not have a superclass or supertype that will be a
- // better candidate.
- return common.where((ClassEntity each) {
- bool containsSuperclass = common.contains(getSuperClass(each));
- // If the superclass is also a candidate, then we don't want to
- // deal with this class. If we're only looking for a subclass we
- // know we don't have to look at the list of interfaces because
- // they can never be in the common set.
- if (containsSuperclass ||
- query1 == ClassQuery.SUBCLASS ||
- query2 == ClassQuery.SUBCLASS) {
- return !containsSuperclass;
- }
- // Run through the direct supertypes of the class. If the common
- // set contains the direct supertype of the class, we ignore the
- // the class because the supertype is a better candidate.
-
- for (ClassEntity interface in getInterfaces(each)) {
- if (common.contains(interface)) return false;
- }
- return true;
- });
- }
-
- /// Applies [f] to each live class that implements [cls] _not_ including [cls]
- /// itself.
- void forEachStrictSubtypeOf(
- ClassEntity cls, IterationStep f(ClassEntity cls)) {
- ClassSet classSet = _classSets[cls];
- if (classSet == null) return;
- classSet.forEachSubtype(f, ClassHierarchyNode.EXPLICITLY_INSTANTIATED,
- strict: true);
- }
}
// Interface for testing equivalence of Kernel-based entities.
diff --git a/pkg/compiler/lib/src/kernel/kernel_strategy.dart b/pkg/compiler/lib/src/kernel/kernel_strategy.dart
index 19e2aa3..9e91d03 100644
--- a/pkg/compiler/lib/src/kernel/kernel_strategy.dart
+++ b/pkg/compiler/lib/src/kernel/kernel_strategy.dart
@@ -31,7 +31,7 @@
import '../native/enqueue.dart' show NativeResolutionEnqueuer;
import '../native/resolver.dart';
import '../options.dart';
-import '../universe/class_hierarchy_builder.dart';
+import '../universe/class_hierarchy.dart';
import '../universe/world_builder.dart';
import '../universe/world_impact.dart';
import 'deferred_load.dart';
diff --git a/pkg/compiler/lib/src/source_file_provider.dart b/pkg/compiler/lib/src/source_file_provider.dart
index 7b4f019..c2d2fd0 100644
--- a/pkg/compiler/lib/src/source_file_provider.dart
+++ b/pkg/compiler/lib/src/source_file_provider.dart
@@ -465,10 +465,10 @@
BazelInputProvider(List<String> searchPaths)
: dirs = searchPaths.map(_resolve).toList();
- static _resolve(String path) => currentDirectory.resolve(path);
+ static Uri _resolve(String path) => currentDirectory.resolve(path);
@override
- Future<api.Input> readFromUri(Uri uri,
+ Future<api.Input<List<int>>> readFromUri(Uri uri,
{InputKind inputKind: InputKind.UTF8}) async {
var resolvedUri = uri;
var path = uri.path;
@@ -482,7 +482,8 @@
}
}
}
- api.Input result = await readBytesFromUri(resolvedUri, inputKind);
+ api.Input<List<int>> result =
+ await readBytesFromUri(resolvedUri, inputKind);
switch (inputKind) {
case InputKind.UTF8:
utf8SourceFiles[uri] = utf8SourceFiles[resolvedUri];
diff --git a/pkg/compiler/lib/src/ssa/builder_kernel.dart b/pkg/compiler/lib/src/ssa/builder_kernel.dart
index be3be29..795ed34 100644
--- a/pkg/compiler/lib/src/ssa/builder_kernel.dart
+++ b/pkg/compiler/lib/src/ssa/builder_kernel.dart
@@ -620,8 +620,8 @@
ConstructorBodyEntity constructorBody =
_elementMap.getConstructorBody(body);
if (!isCustomElement && // TODO(13836): Fix inlining.
- _tryInlineMethod(constructorBody, null, null, bodyCallInputs, node,
- sourceInformation)) {
+ _tryInlineMethod(constructorBody, null, null, bodyCallInputs, null,
+ node, sourceInformation)) {
pop();
} else {
_invokeConstructorBody(body, bodyCallInputs,
@@ -4100,7 +4100,8 @@
AbstractValue typeMask, List<DartType> typeArguments,
{SourceInformation sourceInformation, InterfaceType instanceType}) {
// TODO(redemption): Pass current node if needed.
- if (_tryInlineMethod(target, null, null, arguments, null, sourceInformation,
+ if (_tryInlineMethod(
+ target, null, null, arguments, typeArguments, null, sourceInformation,
instanceType: instanceType)) {
return;
}
@@ -4170,8 +4171,8 @@
!(element.isGetter && selector.isCall) &&
!(element.isFunction && selector.isGetter) &&
!isOptimizableOperation(selector, element)) {
- if (_tryInlineMethod(
- element, selector, mask, arguments, node, sourceInformation)) {
+ if (_tryInlineMethod(element, selector, mask, arguments, typeArguments,
+ node, sourceInformation)) {
return;
}
}
@@ -4988,6 +4989,7 @@
Selector selector,
AbstractValue mask,
List<HInstruction> providedArguments,
+ List<DartType> typeArguments,
ir.Node currentNode,
SourceInformation sourceInformation,
{InterfaceType instanceType}) {
@@ -5149,8 +5151,15 @@
}
void doInlining() {
- registry
- .registerStaticUse(new StaticUse.inlining(function, instanceType));
+ if (function.isConstructor) {
+ registry.registerStaticUse(
+ new StaticUse.constructorInlining(function, instanceType));
+ } else {
+ assert(instanceType == null,
+ "Unexpected instance type for $function: $instanceType");
+ registry.registerStaticUse(
+ new StaticUse.methodInlining(function, typeArguments));
+ }
// Add an explicit null check on the receiver before doing the
// inlining. We use [element] to get the same name in the
diff --git a/pkg/compiler/lib/src/ssa/kernel_impact.dart b/pkg/compiler/lib/src/ssa/kernel_impact.dart
index b5cd0b2..7f5367c 100644
--- a/pkg/compiler/lib/src/ssa/kernel_impact.dart
+++ b/pkg/compiler/lib/src/ssa/kernel_impact.dart
@@ -234,21 +234,6 @@
@override
void visitIntLiteral(ir.IntLiteral literal) {
- // Check that this value can be precisely represented as a double, and throw
- // an error if not:
- if (new BigInt.from(literal.value) !=
- new BigInt.from(literal.value.toDouble())) {
- // TODO(efortuna): Switch to error message.
- reporter.reportWarningMessage(
- CURRENT_ELEMENT_SPANNABLE, MessageKind.GENERIC, {
- 'text': 'The integer literal '
- '${new BigInt.from(literal.value)} cannot be represented'
- ' exactly in JavaScript and will be rounded to '
- '${new BigInt.from(literal.value.toDouble())}. Use the rounded '
- 'value to avoid this warning.'
- });
- }
-
impactBuilder.registerConstantLiteral(new IntConstantExpression(
new BigInt.from(literal.value).toUnsigned(64)));
}
diff --git a/pkg/compiler/lib/src/ssa/optimize.dart b/pkg/compiler/lib/src/ssa/optimize.dart
index cd71861..a0ac620 100644
--- a/pkg/compiler/lib/src/ssa/optimize.dart
+++ b/pkg/compiler/lib/src/ssa/optimize.dart
@@ -665,7 +665,7 @@
node.typeArguments,
node.sourceInformation);
result.element = method;
- _registry.registerStaticUse(new StaticUse.inlining(method, null));
+ _registry.registerStaticUse(new StaticUse.methodInlining(method, null));
return result;
}
@@ -927,7 +927,24 @@
}
HInstruction visitTypeConversion(HTypeConversion node) {
- return node.isRedundant(_closedWorld) ? node.checkedInput : node;
+ if (node.isRedundant(_closedWorld)) return node.checkedInput;
+
+ // Simplify 'as T' where T is a simple type.
+ DartType checkedType = node.typeExpression;
+ if (checkedType is TypeVariableType && node.inputs.length == 2) {
+ HInstruction rep = node.typeRepresentation;
+ if (rep is HTypeInfoExpression &&
+ rep.kind == TypeInfoExpressionKind.COMPLETE &&
+ rep.inputs.isEmpty) {
+ DartType type = rep.dartType;
+ if (type.isInterfaceType && type.treatAsRaw) {
+ return node.checkedInput.convertType(_closedWorld, type, node.kind)
+ ..sourceInformation = node.sourceInformation;
+ }
+ }
+ }
+
+ return node;
}
HInstruction visitTypeKnown(HTypeKnown node) {
diff --git a/pkg/compiler/lib/src/universe/class_hierarchy.dart b/pkg/compiler/lib/src/universe/class_hierarchy.dart
new file mode 100644
index 0000000..f19320a
--- /dev/null
+++ b/pkg/compiler/lib/src/universe/class_hierarchy.dart
@@ -0,0 +1,543 @@
+// Copyright (c) 2017, 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.
+
+import '../common.dart';
+import '../common_elements.dart';
+import '../elements/entities.dart';
+import '../elements/types.dart' show InterfaceType;
+import 'class_set.dart';
+
+// TODO(johnniwinther): Move more methods from `JClosedWorld` to
+// `ClassHierarchy`.
+abstract class ClassHierarchy {
+ /// Returns [ClassHierarchyNode] for [cls] used to model the class hierarchies
+ /// of known classes.
+ ///
+ /// This method is only provided for testing. For queries on classes, use the
+ /// methods defined in [JClosedWorld].
+ ClassHierarchyNode getClassHierarchyNode(ClassEntity cls);
+
+ /// Returns [ClassSet] for [cls] used to model the extends and implements
+ /// relations of known classes.
+ ///
+ /// This method is only provided for testing. For queries on classes, use the
+ /// methods defined in [JClosedWorld].
+ ClassSet getClassSet(ClassEntity cls);
+
+ /// Returns `true` if [x] is a subtype of [y], that is, if [x] implements an
+ /// instance of [y].
+ bool isSubtypeOf(ClassEntity x, ClassEntity y);
+
+ /// Returns a [SubclassResult] for the subclasses that are contained in
+ /// the subclass/subtype sets of both [cls1] and [cls2].
+ ///
+ /// Classes that are implied by included superclasses/supertypes are not
+ /// returned.
+ ///
+ /// For instance for this hierarchy
+ ///
+ /// class A {}
+ /// class B {}
+ /// class C implements A, B {}
+ /// class D extends C {}
+ ///
+ /// the query
+ ///
+ /// commonSubclasses(A, ClassQuery.SUBTYPE, B, ClassQuery.SUBTYPE)
+ ///
+ /// return the set {C} because [D] is implied by [C].
+ SubclassResult commonSubclasses(
+ ClassEntity cls1, ClassQuery query1, ClassEntity cls2, ClassQuery query2);
+
+ /// Returns an iterable over the directly instantiated that implement [cls]
+ /// possibly including [cls] itself, if it is live.
+ Iterable<ClassEntity> subtypesOf(ClassEntity cls);
+
+ /// Returns an iterable over the live classes that extend [cls] including
+ /// [cls] itself.
+ Iterable<ClassEntity> subclassesOf(ClassEntity cls);
+
+ /// Applies [f] to each live class that implements [cls] _not_ including [cls]
+ /// itself.
+ void forEachStrictSubtypeOf(
+ ClassEntity cls, IterationStep f(ClassEntity cls));
+}
+
+class ClassHierarchyImpl implements ClassHierarchy {
+ final CommonElements _commonElements;
+ final Map<ClassEntity, ClassHierarchyNode> _classHierarchyNodes;
+ final Map<ClassEntity, ClassSet> _classSets;
+
+ ClassHierarchyImpl(
+ this._commonElements, this._classHierarchyNodes, this._classSets);
+
+ /// Returns [ClassHierarchyNode] for [cls] used to model the class hierarchies
+ /// of known classes.
+ ///
+ /// This method is only provided for testing. For queries on classes, use the
+ /// methods defined in [JClosedWorld].
+ ClassHierarchyNode getClassHierarchyNode(ClassEntity cls) {
+ return _classHierarchyNodes[cls];
+ }
+
+ /// Returns [ClassSet] for [cls] used to model the extends and implements
+ /// relations of known classes.
+ ///
+ /// This method is only provided for testing. For queries on classes, use the
+ /// methods defined in [JClosedWorld].
+ ClassSet getClassSet(ClassEntity cls) {
+ return _classSets[cls];
+ }
+
+ /// Returns `true` if [x] is a subtype of [y], that is, if [x] implements an
+ /// instance of [y].
+ bool isSubtypeOf(ClassEntity x, ClassEntity y) {
+ ClassSet classSet = _classSets[y];
+ assert(classSet != null,
+ failedAt(y, "No ClassSet for $y (${y.runtimeType}): ${_classSets}"));
+ ClassHierarchyNode classHierarchyNode = _classHierarchyNodes[x];
+ assert(classHierarchyNode != null,
+ failedAt(x, "No ClassHierarchyNode for $x"));
+ return classSet.hasSubtype(classHierarchyNode);
+ }
+
+ /// Return `true` if [x] is a (non-strict) subclass of [y].
+ bool isSubclassOf(ClassEntity x, ClassEntity y) {
+ return _classHierarchyNodes[y].hasSubclass(_classHierarchyNodes[x]);
+ }
+
+ /// Returns an iterable over the directly instantiated that implement [cls]
+ /// possibly including [cls] itself, if it is live.
+ Iterable<ClassEntity> subtypesOf(ClassEntity cls) {
+ ClassSet classSet = _classSets[cls];
+ if (classSet == null) {
+ return const <ClassEntity>[];
+ } else {
+ return classSet
+ .subtypesByMask(ClassHierarchyNode.EXPLICITLY_INSTANTIATED);
+ }
+ }
+
+ /// Returns an iterable over the directly instantiated classes that extend
+ /// [cls] possibly including [cls] itself, if it is live.
+ Iterable<ClassEntity> subclassesOf(ClassEntity cls) {
+ ClassHierarchyNode hierarchy = _classHierarchyNodes[cls];
+ if (hierarchy == null) return const <ClassEntity>[];
+ return hierarchy
+ .subclassesByMask(ClassHierarchyNode.EXPLICITLY_INSTANTIATED);
+ }
+
+ /// Returns an iterable over the directly instantiated that implement [cls]
+ /// _not_ including [cls].
+ Iterable<ClassEntity> strictSubtypesOf(ClassEntity cls) {
+ ClassSet classSet = _classSets[cls];
+ if (classSet == null) {
+ return const <ClassEntity>[];
+ } else {
+ return classSet.subtypesByMask(ClassHierarchyNode.EXPLICITLY_INSTANTIATED,
+ strict: true);
+ }
+ }
+
+ /// Returns an iterable over the directly instantiated classes that extend
+ /// [cls] _not_ including [cls] itself.
+ Iterable<ClassEntity> strictSubclassesOf(ClassEntity cls) {
+ ClassHierarchyNode subclasses = _classHierarchyNodes[cls];
+ if (subclasses == null) return const <ClassEntity>[];
+ return subclasses.subclassesByMask(
+ ClassHierarchyNode.EXPLICITLY_INSTANTIATED,
+ strict: true);
+ }
+
+ /// Applies [f] to each live class that extend [cls] _not_ including [cls]
+ /// itself.
+ void forEachStrictSubclassOf(
+ ClassEntity cls, IterationStep f(ClassEntity cls)) {
+ ClassHierarchyNode subclasses = _classHierarchyNodes[cls];
+ if (subclasses == null) return;
+ subclasses.forEachSubclass(f, ClassHierarchyNode.EXPLICITLY_INSTANTIATED,
+ strict: true);
+ }
+
+ /// Applies [f] to each live class that implements [cls] _not_ including [cls]
+ /// itself.
+ void forEachStrictSubtypeOf(
+ ClassEntity cls, IterationStep f(ClassEntity cls)) {
+ ClassSet classSet = _classSets[cls];
+ if (classSet == null) return;
+ classSet.forEachSubtype(f, ClassHierarchyNode.EXPLICITLY_INSTANTIATED,
+ strict: true);
+ }
+
+ SubclassResult commonSubclasses(ClassEntity cls1, ClassQuery query1,
+ ClassEntity cls2, ClassQuery query2) {
+ if (query1 == ClassQuery.EXACT && query2 == ClassQuery.EXACT) {
+ // Exact classes [cls1] and [cls2] must be identical to have any classes
+ // in common.
+ if (cls1 != cls2) {
+ return const SubclassResult.empty();
+ }
+ return new SubclassResult.exact(cls1);
+ } else if (query1 == ClassQuery.EXACT) {
+ if (query2 == ClassQuery.SUBCLASS) {
+ // Exact [cls1] must be a subclass of [cls2] to have any classes in
+ // common.
+ if (isSubclassOf(cls1, cls2)) {
+ return new SubclassResult.exact(cls1);
+ }
+ } else if (query2 == ClassQuery.SUBTYPE) {
+ // Exact [cls1] must be a subtype of [cls2] to have any classes in
+ // common.
+ if (isSubtypeOf(cls1, cls2)) {
+ return new SubclassResult.exact(cls1);
+ }
+ }
+ return const SubclassResult.empty();
+ } else if (query2 == ClassQuery.EXACT) {
+ if (query1 == ClassQuery.SUBCLASS) {
+ // Exact [cls2] must be a subclass of [cls1] to have any classes in
+ // common.
+ if (isSubclassOf(cls2, cls1)) {
+ return new SubclassResult.exact(cls2);
+ }
+ } else if (query1 == ClassQuery.SUBTYPE) {
+ // Exact [cls2] must be a subtype of [cls1] to have any classes in
+ // common.
+ if (isSubtypeOf(cls2, cls1)) {
+ return new SubclassResult.exact(cls2);
+ }
+ }
+ return const SubclassResult.empty();
+ } else if (query1 == ClassQuery.SUBCLASS && query2 == ClassQuery.SUBCLASS) {
+ // [cls1] must be a subclass of [cls2] or vice versa to have any classes
+ // in common.
+ if (cls1 == cls2 || isSubclassOf(cls1, cls2)) {
+ // The subclasses of [cls1] are contained within the subclasses of
+ // [cls2].
+ return new SubclassResult.subclass(cls1);
+ } else if (isSubclassOf(cls2, cls1)) {
+ // The subclasses of [cls2] are contained within the subclasses of
+ // [cls1].
+ return new SubclassResult.subclass(cls2);
+ }
+ return const SubclassResult.empty();
+ } else if (query1 == ClassQuery.SUBCLASS) {
+ if (isSubtypeOf(cls1, cls2)) {
+ // The subclasses of [cls1] are all subtypes of [cls2].
+ return new SubclassResult.subclass(cls1);
+ }
+ if (cls1 == _commonElements.objectClass) {
+ // Since [cls1] is `Object` all subtypes of [cls2] are contained within
+ // the subclasses of [cls1].
+ return new SubclassResult.subtype(cls2);
+ }
+ // Find all the root subclasses of [cls1] of that implement [cls2].
+ //
+ // For this hierarchy:
+ //
+ // class I {}
+ // class A {}
+ // class B extends A implements I {}
+ // class C extends B {}
+ // class D extends A implements I {}
+ //
+ // the common subclasses of "subclass of A" and "subtype of I" returns
+ // "subclasses of {B, D}". The inclusion of class `C` is implied because
+ // it is a subclass of `B`.
+ List<ClassEntity> classes = <ClassEntity>[];
+ forEachStrictSubclassOf(cls1, (ClassEntity subclass) {
+ if (isSubtypeOf(subclass, cls2)) {
+ classes.add(subclass);
+ // Skip subclasses of [subclass]; they all implement [cls2] by
+ // inheritance and are included in the subclasses of [subclass].
+ return IterationStep.SKIP_SUBCLASSES;
+ }
+ return IterationStep.CONTINUE;
+ });
+ return new SubclassResult.subclasses(classes);
+ } else if (query2 == ClassQuery.SUBCLASS) {
+ if (isSubtypeOf(cls2, cls1)) {
+ // The subclasses of [cls2] are all subtypes of [cls1].
+ return new SubclassResult.subclass(cls2);
+ }
+ if (cls2 == _commonElements.objectClass) {
+ // Since [cls2] is `Object` all subtypes of [cls1] are contained within
+ // the subclasses of [cls2].
+ return new SubclassResult.subtype(cls1);
+ }
+ // Find all the root subclasses of [cls2] of that implement [cls1].
+ List<ClassEntity> classes = <ClassEntity>[];
+ forEachStrictSubclassOf(cls2, (ClassEntity subclass) {
+ if (isSubtypeOf(subclass, cls1)) {
+ classes.add(subclass);
+ // Skip subclasses of [subclass]; they all implement [cls1] by
+ // inheritance and are included in the subclasses of [subclass].
+ return IterationStep.SKIP_SUBCLASSES;
+ }
+ return IterationStep.CONTINUE;
+ });
+ return new SubclassResult.subclasses(classes);
+ } else {
+ if (cls1 == cls2 || isSubtypeOf(cls1, cls2)) {
+ // The subtypes of [cls1] are contained within the subtypes of [cls2].
+ return new SubclassResult.subtype(cls1);
+ } else if (isSubtypeOf(cls2, cls1)) {
+ // The subtypes of [cls2] are contained within the subtypes of [cls1].
+ return new SubclassResult.subtype(cls2);
+ }
+ // Find all the root subclasses of [cls1] of that implement [cls2].
+ //
+ // For this hierarchy:
+ //
+ // class I {}
+ // class A {}
+ // class B extends A implements I {}
+ // class C extends B {}
+ // class D extends A implements I {}
+ // class E implements B {}
+ // class F extends E {}
+ //
+ // the common subclasses of "subtype of A" and "subtype of I" returns
+ // "subclasses of {B, D, E}". The inclusion of classes `C` and `F` is
+ // implied because they are subclasses of `B` and `E`, respectively.
+ List<ClassEntity> classes = <ClassEntity>[];
+ forEachStrictSubtypeOf(cls1, (ClassEntity subclass) {
+ if (isSubtypeOf(subclass, cls2)) {
+ classes.add(subclass);
+ // Skip subclasses of [subclass]; they all implement [cls2] by
+ // inheritance and are included in the subclasses of [subclass].
+ return IterationStep.SKIP_SUBCLASSES;
+ }
+ return IterationStep.CONTINUE;
+ });
+ return new SubclassResult.subclasses(classes);
+ }
+ }
+}
+
+class ClassHierarchyBuilder {
+ // We keep track of subtype and subclass relationships in four
+ // distinct sets to make class hierarchy analysis faster.
+ final Map<ClassEntity, ClassHierarchyNode> classHierarchyNodes =
+ <ClassEntity, ClassHierarchyNode>{};
+ final Map<ClassEntity, ClassSet> classSets = <ClassEntity, ClassSet>{};
+ final Map<ClassEntity, Set<ClassEntity>> mixinUses =
+ new Map<ClassEntity, Set<ClassEntity>>();
+
+ final CommonElements _commonElements;
+ final ClassQueries _classQueries;
+
+ ClassHierarchyBuilder(this._commonElements, this._classQueries);
+
+ void registerClass(ClassEntity cls) {
+ _ensureClassSet(_classQueries.getDeclaration(cls));
+ }
+
+ ClassHierarchyNode _ensureClassHierarchyNode(ClassEntity cls) {
+ assert(_classQueries.checkClass(cls));
+ return classHierarchyNodes.putIfAbsent(cls, () {
+ ClassHierarchyNode parentNode;
+ ClassEntity superclass = _classQueries.getSuperClass(cls);
+ if (superclass != null) {
+ parentNode = _ensureClassHierarchyNode(superclass);
+ }
+ return new ClassHierarchyNode(
+ parentNode, cls, _classQueries.getHierarchyDepth(cls));
+ });
+ }
+
+ ClassSet _ensureClassSet(ClassEntity cls) {
+ assert(_classQueries.checkClass(cls));
+ return classSets.putIfAbsent(cls, () {
+ ClassHierarchyNode node = _ensureClassHierarchyNode(cls);
+ ClassSet classSet = new ClassSet(node);
+
+ for (InterfaceType type in _classQueries.getSupertypes(cls)) {
+ // TODO(johnniwinther): Optimization: Avoid adding [cls] to
+ // superclasses.
+ ClassSet subtypeSet = _ensureClassSet(type.element);
+ subtypeSet.addSubtype(node);
+ }
+
+ ClassEntity appliedMixin = _classQueries.getAppliedMixin(cls);
+ while (appliedMixin != null) {
+ // TODO(johnniwinther): Use the data stored in [ClassSet].
+ registerMixinUse(cls, appliedMixin);
+ ClassSet mixinSet = _ensureClassSet(appliedMixin);
+ mixinSet.addMixinApplication(node);
+
+ // In case of
+ //
+ // class A {}
+ // class B = Object with A;
+ // class C = Object with B;
+ //
+ // we need to register that C not only mixes in B but also A.
+ appliedMixin = _classQueries.getAppliedMixin(appliedMixin);
+ }
+ return classSet;
+ });
+ }
+
+ void _updateSuperClassHierarchyNodeForClass(ClassHierarchyNode node) {
+ // Ensure that classes implicitly implementing `Function` are in its
+ // subtype set.
+ ClassEntity cls = node.cls;
+ if (cls != _commonElements.functionClass &&
+ _classQueries.implementsFunction(cls)) {
+ ClassSet subtypeSet = _ensureClassSet(_commonElements.functionClass);
+ subtypeSet.addSubtype(node);
+ }
+ if (!node.isInstantiated && node.parentNode != null) {
+ _updateSuperClassHierarchyNodeForClass(node.parentNode);
+ }
+ }
+
+ void updateClassHierarchyNodeForClass(ClassEntity cls,
+ {bool directlyInstantiated: false, bool abstractlyInstantiated: false}) {
+ ClassHierarchyNode node = _ensureClassSet(cls).node;
+ _updateSuperClassHierarchyNodeForClass(node);
+ if (directlyInstantiated) {
+ node.isDirectlyInstantiated = true;
+ }
+ if (abstractlyInstantiated) {
+ node.isAbstractlyInstantiated = true;
+ }
+ }
+
+ void registerMixinUse(ClassEntity mixinApplication, ClassEntity mixin) {
+ // TODO(johnniwinther): Add map restricted to live classes.
+ // We don't support patch classes as mixin.
+ Set<ClassEntity> users =
+ mixinUses.putIfAbsent(mixin, () => new Set<ClassEntity>());
+ users.add(mixinApplication);
+ }
+
+ bool _isSubtypeOf(ClassEntity x, ClassEntity y) {
+ assert(
+ classSets.containsKey(x), "ClassSet for $x has not been computed yet.");
+ ClassSet classSet = classSets[y];
+ assert(classSet != null,
+ failedAt(y, "No ClassSet for $y (${y.runtimeType}): ${classSets}"));
+ ClassHierarchyNode classHierarchyNode = classHierarchyNodes[x];
+ assert(classHierarchyNode != null,
+ failedAt(x, "No ClassHierarchyNode for $x"));
+ return classSet.hasSubtype(classHierarchyNode);
+ }
+
+ bool isInheritedInSubtypeOf(ClassEntity x, ClassEntity y) {
+ ClassSet classSet = classSets[x];
+ assert(classSet != null,
+ failedAt(x, "No ClassSet for $x (${x.runtimeType}): ${classSets}"));
+
+ if (_isSubtypeOf(x, y)) {
+ // [x] implements [y] itself, possible through supertypes.
+ return true;
+ }
+
+ /// Returns `true` if any live subclass of [node] implements [y].
+ bool subclassImplements(ClassHierarchyNode node, {bool strict}) {
+ return node.anySubclass((ClassEntity z) => _isSubtypeOf(z, y),
+ ClassHierarchyNode.INSTANTIATED,
+ strict: strict);
+ }
+
+ if (subclassImplements(classSet.node, strict: true)) {
+ // A subclass of [x] implements [y].
+ return true;
+ }
+
+ for (ClassHierarchyNode mixinApplication
+ in classSet.mixinApplicationNodes) {
+ if (subclassImplements(mixinApplication, strict: false)) {
+ // A subclass of [mixinApplication] implements [y].
+ return true;
+ }
+ }
+ return false;
+ }
+}
+
+abstract class ClassQueries {
+ bool checkClass(covariant ClassEntity cls);
+ bool validateClass(covariant ClassEntity cls);
+
+ /// Returns the declaration of [cls].
+ ClassEntity getDeclaration(covariant ClassEntity cls);
+
+ /// Returns the class mixed into [cls] if any.
+ // TODO(johnniwinther): Replace this by a `getAppliedMixins` function that
+ // return transitively mixed in classes like in:
+ // class A {}
+ // class B = Object with A;
+ // class C = Object with B;
+ ClassEntity getAppliedMixin(covariant ClassEntity cls);
+
+ /// Returns the hierarchy depth of [cls].
+ int getHierarchyDepth(covariant ClassEntity cls);
+
+ /// Returns `true` if [cls] implements `Function` either explicitly or through
+ /// a `call` method.
+ bool implementsFunction(covariant ClassEntity cls);
+
+ /// Returns the superclass of [cls] if any.
+ ClassEntity getSuperClass(covariant ClassEntity cls);
+
+ /// Returns all supertypes of [cls].
+ Iterable<InterfaceType> getSupertypes(covariant ClassEntity cls);
+}
+
+/// Enum values defining subset of classes included in queries.
+enum ClassQuery {
+ /// Only the class itself is included.
+ EXACT,
+
+ /// The class and all subclasses (transitively) are included.
+ SUBCLASS,
+
+ /// The class and all classes that implement or subclass it (transitively)
+ /// are included.
+ SUBTYPE,
+}
+
+/// Result computed in [ClassHierarchy.commonSubclasses].
+class SubclassResult {
+ /// The classes in the result set. The classes are always disjoint wrt. the
+ /// interpretation of [query].
+ final List<ClassEntity> classes;
+
+ /// How [classes] should be interpreted: If `ClassQuery.EXACT`, only the
+ /// classes in [classes] are on the result set. If `ClassQuery.SUBCLASS`,
+ /// non-strict subclasses of the classes in [classes] are in the result set.
+ /// If `ClassQuery.SUBTYPE`, non-strict subtypes of the classes in [classes]
+ /// are in the result set.
+ final ClassQuery query;
+
+ /// Creates the empty result set.
+ const SubclassResult.empty()
+ : query = ClassQuery.EXACT,
+ classes = const <ClassEntity>[];
+
+ /// Creates the single set of [cls].
+ SubclassResult.exact(ClassEntity cls)
+ : query = ClassQuery.EXACT,
+ classes = <ClassEntity>[cls];
+
+ /// Creates the set of subclasses of [cls].
+ SubclassResult.subclass(ClassEntity cls)
+ : query = ClassQuery.SUBCLASS,
+ classes = <ClassEntity>[cls];
+
+ /// Creates the set of subtypes of [cls].
+ SubclassResult.subtype(ClassEntity cls)
+ : query = ClassQuery.SUBTYPE,
+ classes = <ClassEntity>[cls];
+
+ /// Creates the set of classes that are subclasses of a class in [classes].
+ SubclassResult.subclasses(this.classes) : query = ClassQuery.SUBCLASS;
+
+ SubclassResult.internal(this.query, this.classes);
+
+ String toString() => 'SubclassResult($query,$classes)';
+}
diff --git a/pkg/compiler/lib/src/universe/class_hierarchy_builder.dart b/pkg/compiler/lib/src/universe/class_hierarchy_builder.dart
deleted file mode 100644
index 337975f..0000000
--- a/pkg/compiler/lib/src/universe/class_hierarchy_builder.dart
+++ /dev/null
@@ -1,181 +0,0 @@
-// Copyright (c) 2017, 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.
-
-import '../common.dart';
-import '../common_elements.dart';
-import '../elements/entities.dart';
-import '../elements/types.dart' show InterfaceType;
-import 'class_set.dart';
-
-class ClassHierarchyBuilder {
- // We keep track of subtype and subclass relationships in four
- // distinct sets to make class hierarchy analysis faster.
- final Map<ClassEntity, ClassHierarchyNode> classHierarchyNodes =
- <ClassEntity, ClassHierarchyNode>{};
- final Map<ClassEntity, ClassSet> classSets = <ClassEntity, ClassSet>{};
- final Map<ClassEntity, Set<ClassEntity>> mixinUses =
- new Map<ClassEntity, Set<ClassEntity>>();
-
- final CommonElements _commonElements;
- final ClassQueries _classQueries;
-
- ClassHierarchyBuilder(this._commonElements, this._classQueries);
-
- void registerClass(ClassEntity cls) {
- _ensureClassSet(_classQueries.getDeclaration(cls));
- }
-
- ClassHierarchyNode _ensureClassHierarchyNode(ClassEntity cls) {
- assert(_classQueries.checkClass(cls));
- return classHierarchyNodes.putIfAbsent(cls, () {
- ClassHierarchyNode parentNode;
- ClassEntity superclass = _classQueries.getSuperClass(cls);
- if (superclass != null) {
- parentNode = _ensureClassHierarchyNode(superclass);
- }
- return new ClassHierarchyNode(
- parentNode, cls, _classQueries.getHierarchyDepth(cls));
- });
- }
-
- ClassSet _ensureClassSet(ClassEntity cls) {
- assert(_classQueries.checkClass(cls));
- return classSets.putIfAbsent(cls, () {
- ClassHierarchyNode node = _ensureClassHierarchyNode(cls);
- ClassSet classSet = new ClassSet(node);
-
- for (InterfaceType type in _classQueries.getSupertypes(cls)) {
- // TODO(johnniwinther): Optimization: Avoid adding [cls] to
- // superclasses.
- ClassSet subtypeSet = _ensureClassSet(type.element);
- subtypeSet.addSubtype(node);
- }
-
- ClassEntity appliedMixin = _classQueries.getAppliedMixin(cls);
- while (appliedMixin != null) {
- // TODO(johnniwinther): Use the data stored in [ClassSet].
- registerMixinUse(cls, appliedMixin);
- ClassSet mixinSet = _ensureClassSet(appliedMixin);
- mixinSet.addMixinApplication(node);
-
- // In case of
- //
- // class A {}
- // class B = Object with A;
- // class C = Object with B;
- //
- // we need to register that C not only mixes in B but also A.
- appliedMixin = _classQueries.getAppliedMixin(appliedMixin);
- }
- return classSet;
- });
- }
-
- void _updateSuperClassHierarchyNodeForClass(ClassHierarchyNode node) {
- // Ensure that classes implicitly implementing `Function` are in its
- // subtype set.
- ClassEntity cls = node.cls;
- if (cls != _commonElements.functionClass &&
- _classQueries.implementsFunction(cls)) {
- ClassSet subtypeSet = _ensureClassSet(_commonElements.functionClass);
- subtypeSet.addSubtype(node);
- }
- if (!node.isInstantiated && node.parentNode != null) {
- _updateSuperClassHierarchyNodeForClass(node.parentNode);
- }
- }
-
- void updateClassHierarchyNodeForClass(ClassEntity cls,
- {bool directlyInstantiated: false, bool abstractlyInstantiated: false}) {
- ClassHierarchyNode node = _ensureClassSet(cls).node;
- _updateSuperClassHierarchyNodeForClass(node);
- if (directlyInstantiated) {
- node.isDirectlyInstantiated = true;
- }
- if (abstractlyInstantiated) {
- node.isAbstractlyInstantiated = true;
- }
- }
-
- void registerMixinUse(ClassEntity mixinApplication, ClassEntity mixin) {
- // TODO(johnniwinther): Add map restricted to live classes.
- // We don't support patch classes as mixin.
- Set<ClassEntity> users =
- mixinUses.putIfAbsent(mixin, () => new Set<ClassEntity>());
- users.add(mixinApplication);
- }
-
- bool _isSubtypeOf(ClassEntity x, ClassEntity y) {
- assert(
- classSets.containsKey(x), "ClassSet for $x has not been computed yet.");
- ClassSet classSet = classSets[y];
- assert(classSet != null,
- failedAt(y, "No ClassSet for $y (${y.runtimeType}): ${classSets}"));
- ClassHierarchyNode classHierarchyNode = classHierarchyNodes[x];
- assert(classHierarchyNode != null,
- failedAt(x, "No ClassHierarchyNode for $x"));
- return classSet.hasSubtype(classHierarchyNode);
- }
-
- bool isInheritedInSubtypeOf(ClassEntity x, ClassEntity y) {
- ClassSet classSet = classSets[x];
- assert(classSet != null,
- failedAt(x, "No ClassSet for $x (${x.runtimeType}): ${classSets}"));
-
- if (_isSubtypeOf(x, y)) {
- // [x] implements [y] itself, possible through supertypes.
- return true;
- }
-
- /// Returns `true` if any live subclass of [node] implements [y].
- bool subclassImplements(ClassHierarchyNode node, {bool strict}) {
- return node.anySubclass((ClassEntity z) => _isSubtypeOf(z, y),
- ClassHierarchyNode.INSTANTIATED,
- strict: strict);
- }
-
- if (subclassImplements(classSet.node, strict: true)) {
- // A subclass of [x] implements [y].
- return true;
- }
-
- for (ClassHierarchyNode mixinApplication
- in classSet.mixinApplicationNodes) {
- if (subclassImplements(mixinApplication, strict: false)) {
- // A subclass of [mixinApplication] implements [y].
- return true;
- }
- }
- return false;
- }
-}
-
-abstract class ClassQueries {
- bool checkClass(covariant ClassEntity cls);
- bool validateClass(covariant ClassEntity cls);
-
- /// Returns the declaration of [cls].
- ClassEntity getDeclaration(covariant ClassEntity cls);
-
- /// Returns the class mixed into [cls] if any.
- // TODO(johnniwinther): Replace this by a `getAppliedMixins` function that
- // return transitively mixed in classes like in:
- // class A {}
- // class B = Object with A;
- // class C = Object with B;
- ClassEntity getAppliedMixin(covariant ClassEntity cls);
-
- /// Returns the hierarchy depth of [cls].
- int getHierarchyDepth(covariant ClassEntity cls);
-
- /// Returns `true` if [cls] implements `Function` either explicitly or through
- /// a `call` method.
- bool implementsFunction(covariant ClassEntity cls);
-
- /// Returns the superclass of [cls] if any.
- ClassEntity getSuperClass(covariant ClassEntity cls);
-
- /// Returns all supertypes of [cls].
- Iterable<InterfaceType> getSupertypes(covariant ClassEntity cls);
-}
diff --git a/pkg/compiler/lib/src/universe/codegen_world_builder.dart b/pkg/compiler/lib/src/universe/codegen_world_builder.dart
index b0f526e..dc49fe5 100644
--- a/pkg/compiler/lib/src/universe/codegen_world_builder.dart
+++ b/pkg/compiler/lib/src/universe/codegen_world_builder.dart
@@ -445,6 +445,7 @@
}
break;
case StaticUseKind.INLINING:
+ registerStaticInvocation(staticUse);
break;
}
if (useSet.isNotEmpty) {
diff --git a/pkg/compiler/lib/src/universe/use.dart b/pkg/compiler/lib/src/universe/use.dart
index 8788342..0db511d 100644
--- a/pkg/compiler/lib/src/universe/use.dart
+++ b/pkg/compiler/lib/src/universe/use.dart
@@ -523,12 +523,18 @@
}
/// Inlining of [element].
- factory StaticUse.inlining(
- FunctionEntity element, InterfaceType instanceType) {
+ factory StaticUse.constructorInlining(
+ ConstructorEntity element, InterfaceType instanceType) {
return new StaticUse.internal(element, StaticUseKind.INLINING,
type: instanceType);
}
+ /// Inlining of [element].
+ factory StaticUse.methodInlining(
+ FunctionEntity element, List<DartType> typeArguments) {
+ return new GenericStaticUse.methodInlining(element, typeArguments);
+ }
+
bool operator ==(other) {
if (identical(this, other)) return true;
if (other is! StaticUse) return false;
@@ -540,7 +546,7 @@
}
String toString() =>
- 'StaticUse($element,$kind,$type,' '$typeArguments,$callStructure)';
+ 'StaticUse($element,$kind,$type,$typeArguments,$callStructure)';
}
class GenericStaticUse extends StaticUse {
@@ -559,6 +565,10 @@
"${callStructure?.typeArgumentCount ?? 0} but "
"${typeArguments?.length ?? 0} were passed."));
}
+
+ GenericStaticUse.methodInlining(FunctionEntity entity, this.typeArguments)
+ : super.internal(entity, StaticUseKind.INLINING,
+ typeArgumentsHash: Hashing.listHash(typeArguments));
}
enum TypeUseKind {
diff --git a/pkg/compiler/lib/src/universe/world_builder.dart b/pkg/compiler/lib/src/universe/world_builder.dart
index c1bf88d..2417fd3 100644
--- a/pkg/compiler/lib/src/universe/world_builder.dart
+++ b/pkg/compiler/lib/src/universe/world_builder.dart
@@ -28,7 +28,7 @@
import '../util/enumset.dart';
import '../util/util.dart';
import '../world.dart' show World, JClosedWorld, KClosedWorld, OpenWorld;
-import 'class_hierarchy_builder.dart' show ClassHierarchyBuilder, ClassQueries;
+import 'class_hierarchy.dart' show ClassHierarchyBuilder, ClassQueries;
import 'selector.dart' show Selector;
import 'use.dart'
show
diff --git a/pkg/compiler/lib/src/world.dart b/pkg/compiler/lib/src/world.dart
index 2a33f49..d440deb 100644
--- a/pkg/compiler/lib/src/world.dart
+++ b/pkg/compiler/lib/src/world.dart
@@ -23,6 +23,7 @@
import 'ordered_typeset.dart';
import 'options.dart';
import 'types/abstract_value_domain.dart';
+import 'universe/class_hierarchy.dart';
import 'universe/class_set.dart';
import 'universe/function_set.dart' show FunctionSet;
import 'universe/selector.dart' show Selector;
@@ -68,6 +69,8 @@
Iterable<MemberEntity> get processedMembers;
+ ClassHierarchy get classHierarchy;
+
/// Returns `true` if [cls] is either directly or indirectly instantiated.
bool isInstantiated(ClassEntity cls);
@@ -172,27 +175,6 @@
/// Returns an iterable over the common supertypes of the [classes].
Iterable<ClassEntity> commonSupertypesOf(Iterable<ClassEntity> classes);
- /// Returns an iterable of the classes that are contained in the
- /// strict subclass/subtype sets of both [cls1] and [cls2].
- ///
- /// Classes that are implied by included superclasses/supertypes are not
- /// returned.
- ///
- /// For instance for this hierarchy
- ///
- /// class A {}
- /// class B {}
- /// class C implements A, B {}
- /// class D extends C {}
- ///
- /// the query
- ///
- /// commonSubclasses(A, ClassQuery.SUBTYPE, B, ClassQuery.SUBTYPE)
- ///
- /// return the set {C} because [D] is implied by [C].
- Iterable<ClassEntity> commonSubclasses(
- ClassEntity cls1, ClassQuery query1, ClassEntity cls2, ClassQuery query2);
-
/// Returns an iterable over the live mixin applications that mixin [cls].
Iterable<ClassEntity> mixinUsesOf(ClassEntity cls);
@@ -355,19 +337,6 @@
bool isInheritedInSubtypeOf(MemberEntity member, ClassEntity type);
}
-/// Enum values defining subset of classes included in queries.
-enum ClassQuery {
- /// Only the class itself is included.
- EXACT,
-
- /// The class and all subclasses (transitively) are included.
- SUBCLASS,
-
- /// The class and all classes that implement or subclass it (transitively)
- /// are included.
- SUBTYPE,
-}
-
abstract class ClosedWorldBase implements JClosedWorld {
final ConstantSystem constantSystem;
final NativeData nativeData;
@@ -404,6 +373,8 @@
final Iterable<MemberEntity> processedMembers;
+ final ClassHierarchy classHierarchy;
+
ClosedWorldBase(
this.elementEnvironment,
this.dartTypes,
@@ -425,7 +396,9 @@
AbstractValueStrategy abstractValueStrategy)
: this._implementedClasses = implementedClasses,
this._classHierarchyNodes = classHierarchyNodes,
- this._classSets = classSets {}
+ this._classSets = classSets,
+ classHierarchy = new ClassHierarchyImpl(
+ commonElements, classHierarchyNodes, classSets) {}
bool checkEntity(covariant Entity element);
@@ -665,27 +638,6 @@
return classSet != null ? classSet.getLubOfInstantiatedSubtypes() : null;
}
- Set<ClassEntity> _commonContainedClasses(ClassEntity cls1, ClassQuery query1,
- ClassEntity cls2, ClassQuery query2) {
- Iterable<ClassEntity> xSubset = _containedSubset(cls1, query1);
- if (xSubset == null) return null;
- Iterable<ClassEntity> ySubset = _containedSubset(cls2, query2);
- if (ySubset == null) return null;
- return xSubset.toSet().intersection(ySubset.toSet());
- }
-
- Iterable<ClassEntity> _containedSubset(ClassEntity cls, ClassQuery query) {
- switch (query) {
- case ClassQuery.EXACT:
- return null;
- case ClassQuery.SUBCLASS:
- return strictSubclassesOf(cls);
- case ClassQuery.SUBTYPE:
- return strictSubtypesOf(cls);
- }
- throw new ArgumentError('Unexpected query: $query.');
- }
-
/// Returns `true` if [cls] is mixed into a live class.
bool isUsedAsMixin(ClassEntity cls) {
return !mixinUsesOf(cls).isEmpty;
@@ -809,38 +761,6 @@
return commonSupertypes;
}
- Iterable<ClassEntity> commonSubclasses(ClassEntity cls1, ClassQuery query1,
- ClassEntity cls2, ClassQuery query2) {
- // TODO(johnniwinther): Use [ClassSet] to compute this.
- // Compute the set of classes that are contained in both class subsets.
- Set<ClassEntity> common =
- _commonContainedClasses(cls1, query1, cls2, query2);
- if (common == null || common.isEmpty) return const <ClassEntity>[];
- // Narrow down the candidates by only looking at common classes
- // that do not have a superclass or supertype that will be a
- // better candidate.
- return common.where((ClassEntity each) {
- bool containsSuperclass = common.contains(getSuperClass(each));
- // If the superclass is also a candidate, then we don't want to
- // deal with this class. If we're only looking for a subclass we
- // know we don't have to look at the list of interfaces because
- // they can never be in the common set.
- if (containsSuperclass ||
- query1 == ClassQuery.SUBCLASS ||
- query2 == ClassQuery.SUBCLASS) {
- return !containsSuperclass;
- }
- // Run through the direct supertypes of the class. If the common
- // set contains the direct supertype of the class, we ignore the
- // the class because the supertype is a better candidate.
-
- for (ClassEntity interface in getInterfaces(each)) {
- if (common.contains(interface)) return false;
- }
- return true;
- });
- }
-
/// Returns an iterable over the live mixin applications that mixin [cls].
Iterable<ClassEntity> mixinUsesOf(ClassEntity cls) {
if (_liveMixinUses == null) {
@@ -1037,23 +957,11 @@
InterceptorData get interceptorData;
ElementEnvironment get elementEnvironment;
CommonElements get commonElements;
+ ClassHierarchy get classHierarchy;
/// Returns `true` if [cls] is implemented by an instantiated class.
bool isImplemented(ClassEntity cls);
- /// Returns [ClassHierarchyNode] for [cls] used to model the class hierarchies
- /// of known classes.
- ///
- /// This method is only provided for testing. For queries on classes, use the
- /// methods defined in [JClosedWorld].
- ClassHierarchyNode getClassHierarchyNode(ClassEntity cls);
-