Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(856)

Unified Diff: pkg/analyzer/test/generated/parser_test.dart

Issue 2477183002: When DefaultFormalParameter, don't use ParameterKind.REQUIRED. (Closed)
Patch Set: Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/analyzer/lib/src/generated/parser.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/test/generated/parser_test.dart
diff --git a/pkg/analyzer/test/generated/parser_test.dart b/pkg/analyzer/test/generated/parser_test.dart
index e4b714c87b4ee8294346fb0f6d242278b999e0d0..a7638b834fe80685b9393c3cd54a39d05ea47e45 100644
--- a/pkg/analyzer/test/generated/parser_test.dart
+++ b/pkg/analyzer/test/generated/parser_test.dart
@@ -2166,6 +2166,8 @@ class Foo {
expectNotNullIfNoErrors(list);
listener
.assertErrorsWithCodes([ParserErrorCode.NAMED_PARAMETER_OUTSIDE_GROUP]);
+ expect(list.parameters[0].kind, ParameterKind.REQUIRED);
+ expect(list.parameters[1].kind, ParameterKind.NAMED);
}
void test_nonConstructorFactory_field() {
@@ -2292,6 +2294,8 @@ class Foo {
expectNotNullIfNoErrors(list);
listener.assertErrorsWithCodes(
[ParserErrorCode.POSITIONAL_PARAMETER_OUTSIDE_GROUP]);
+ expect(list.parameters[0].kind, ParameterKind.REQUIRED);
+ expect(list.parameters[1].kind, ParameterKind.POSITIONAL);
}
void test_redirectingConstructorWithBody_named() {
« no previous file with comments | « pkg/analyzer/lib/src/generated/parser.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698