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

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

Issue 692303003: Fix for issue 19100 - better recovery (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 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 fc1eeb84e7461beace758d91f51effa54a8becb7..4383702ec810394a023f3ca11b327eca3fe22176 100644
--- a/pkg/analyzer/test/generated/parser_test.dart
+++ b/pkg/analyzer/test/generated/parser_test.dart
@@ -5683,6 +5683,12 @@ void''', []);
expect(result.type, isNotNull);
}
+ void test_parseFinalConstVarOrType_type_prefixed_noIdentifier() {
+ FinalConstVarOrType result = ParserTestCase.parse("parseFinalConstVarOrType", <Object> [false], "p.A,");
+ expect(result.keyword, isNull);
+ expect(result.type, isNotNull);
+ }
+
void test_parseFinalConstVarOrType_type_prefixedAndParameterized() {
FinalConstVarOrType result = ParserTestCase.parse("parseFinalConstVarOrType", <Object> [false], "p.A<B> a");
expect(result.keyword, isNull);
@@ -5704,6 +5710,18 @@ void''', []);
expect(result.type, isNull);
}
+ void test_parseFinalConstVarOrType_void() {
+ FinalConstVarOrType result = ParserTestCase.parse("parseFinalConstVarOrType", <Object> [false], "void f()");
+ expect(result.keyword, isNull);
+ expect(result.type, isNotNull);
+ }
+
+ void test_parseFinalConstVarOrType_void_noIdentifier() {
+ FinalConstVarOrType result = ParserTestCase.parse("parseFinalConstVarOrType", <Object> [false], "void,");
+ expect(result.keyword, isNull);
+ expect(result.type, isNotNull);
+ }
+
void test_parseFormalParameter_final_withType_named() {
ParameterKind kind = ParameterKind.NAMED;
DefaultFormalParameter parameter = ParserTestCase.parse("parseFormalParameter", <Object> [kind], "final A a : null");
« 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