Version 2.10.0-122.0.dev
Merge commit 'e6ffc0b285fb393ba04c4afa35f9a7eae0e05793' into 'dev'
diff --git a/pkg/_fe_analyzer_shared/lib/src/messages/codes_generated.dart b/pkg/_fe_analyzer_shared/lib/src/messages/codes_generated.dart
index 9c8d78d..0e4375a 100644
--- a/pkg/_fe_analyzer_shared/lib/src/messages/codes_generated.dart
+++ b/pkg/_fe_analyzer_shared/lib/src/messages/codes_generated.dart
@@ -2837,6 +2837,7 @@
const Template<Message Function(Token token)> templateExpectedIdentifier =
const Template<Message Function(Token token)>(
messageTemplate: r"""Expected an identifier, but got '#lexeme'.""",
+ tipTemplate: r"""Try inserting an identifier before '#lexeme'.""",
withArguments: _withArgumentsExpectedIdentifier);
// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
@@ -2850,6 +2851,36 @@
String lexeme = token.lexeme;
return new Message(codeExpectedIdentifier,
message: """Expected an identifier, but got '${lexeme}'.""",
+ tip: """Try inserting an identifier before '${lexeme}'.""",
+ arguments: {'token': token});
+}
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Template<
+ Message Function(
+ Token
+ token)> templateExpectedIdentifierButGotKeyword = const Template<
+ Message Function(
+ Token token)>(
+ messageTemplate:
+ r"""'#lexeme' can't be used as an identifier because it's a keyword.""",
+ tipTemplate:
+ r"""Try renaming this to be an identifier that isn't a keyword.""",
+ withArguments: _withArgumentsExpectedIdentifierButGotKeyword);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Message Function(Token token)> codeExpectedIdentifierButGotKeyword =
+ const Code<Message Function(Token token)>("ExpectedIdentifierButGotKeyword",
+ templateExpectedIdentifierButGotKeyword,
+ index: 113);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+Message _withArgumentsExpectedIdentifierButGotKeyword(Token token) {
+ String lexeme = token.lexeme;
+ return new Message(codeExpectedIdentifierButGotKeyword,
+ message:
+ """'${lexeme}' can't be used as an identifier because it's a keyword.""",
+ tip: """Try renaming this to be an identifier that isn't a keyword.""",
arguments: {'token': token});
}
diff --git a/pkg/_fe_analyzer_shared/lib/src/parser/identifier_context_impl.dart b/pkg/_fe_analyzer_shared/lib/src/parser/identifier_context_impl.dart
index 7b8ebfb..5c94a3f 100644
--- a/pkg/_fe_analyzer_shared/lib/src/parser/identifier_context_impl.dart
+++ b/pkg/_fe_analyzer_shared/lib/src/parser/identifier_context_impl.dart
@@ -67,12 +67,16 @@
parser.reportRecoverableErrorWithToken(
identifier, codes.templateBuiltInIdentifierInDeclaration);
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -112,12 +116,16 @@
identifier = parser.insertSyntheticIdentifier(token, this,
message: codes.templateExpectedIdentifier.withArguments(identifier));
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -152,8 +160,9 @@
identifier = parser.insertSyntheticIdentifier(token, this,
message: codes.templateExpectedIdentifier.withArguments(identifier));
} else {
+ // Use the keyword as the identifier.
parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
return identifier;
}
@@ -189,12 +198,16 @@
identifier = parser.insertSyntheticIdentifier(token, this,
message: codes.templateExpectedIdentifier.withArguments(identifier));
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -224,12 +237,16 @@
parser.reportRecoverableErrorWithToken(
identifier, codes.templateBuiltInIdentifierInDeclaration);
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -250,15 +267,21 @@
}
// Recovery
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (looksLikeStartOfNextTopLevelDeclaration(identifier) ||
isOneOfOrEof(identifier, const [',', '}'])) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
return parser.rewriter.insertSyntheticIdentifier(token);
} else if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
return parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
return identifier;
}
@@ -296,16 +319,20 @@
}
// Recovery
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
+ Token reportErrorAt = identifier;
if (optional(r'$', token) &&
identifier.isKeyword &&
identifier.next.kind == STRING_TOKEN) {
// Keyword used as identifier in string interpolation
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
return identifier;
} else if (!looksLikeStatementStart(identifier)) {
if (identifier.isKeywordOrIdentifier) {
if (isContinuation || !isOneOfOrEof(identifier, const ['as', 'is'])) {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
return identifier;
}
} else if (!identifier.isOperator &&
@@ -316,6 +343,10 @@
identifier = token.next;
}
}
+
+ parser.reportRecoverableErrorWithToken(
+ reportErrorAt, codes.templateExpectedIdentifier);
+
// Insert a synthetic identifier to satisfy listeners.
return parser.rewriter.insertSyntheticIdentifier(token);
}
@@ -337,6 +368,7 @@
// Recovery
if (isOneOfOrEof(identifier, const [';', '=', ',', '}']) ||
looksLikeStartOfNextClassMember(identifier)) {
+ // TODO(jensj): Why aren't an error reported here?
return parser.insertSyntheticIdentifier(token, this);
} else if (!identifier.isKeywordOrIdentifier) {
// When in doubt, consume the token to ensure we make progress
@@ -345,8 +377,9 @@
message: codes.templateExpectedIdentifier.withArguments(identifier),
messageOnToken: identifier);
} else {
+ // Use the keyword as the identifier.
parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
return identifier;
}
}
@@ -360,13 +393,13 @@
return identifier;
}
// If not recovered, recover as normal.
- if (!isRecovered || !token.isKeywordOrIdentifier) {
+ if (!isRecovered || !identifier.isKeywordOrIdentifier) {
return ensureIdentifier(token, parser);
}
// If already recovered, use the given token.
parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
return identifier;
}
}
@@ -425,12 +458,16 @@
identifier = parser.insertSyntheticIdentifier(token, this,
message: codes.templateExpectedIdentifier.withArguments(identifier));
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -469,12 +506,16 @@
identifier = parser.insertSyntheticIdentifier(token, this,
message: codes.templateExpectedIdentifier.withArguments(identifier));
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -528,12 +569,16 @@
identifier = parser.insertSyntheticIdentifier(token, this,
message: codes.templateExpectedIdentifier.withArguments(identifier));
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -560,12 +605,16 @@
identifier = parser.insertSyntheticIdentifier(token, this,
message: codes.templateExpectedIdentifier.withArguments(identifier));
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -590,12 +639,16 @@
identifier = parser.insertSyntheticIdentifier(token, this,
message: codes.templateExpectedIdentifier.withArguments(identifier));
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -644,12 +697,16 @@
identifier = parser.insertSyntheticIdentifier(token, this,
message: codes.templateExpectedIdentifier.withArguments(identifier));
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -677,12 +734,16 @@
identifier = parser.insertSyntheticIdentifier(token, this,
message: codes.templateExpectedIdentifier.withArguments(identifier));
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -719,12 +780,16 @@
identifier = parser.insertSyntheticIdentifier(token, this,
message: codes.templateExpectedIdentifier.withArguments(identifier));
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -768,8 +833,9 @@
message: codes.templateExpectedIdentifier.withArguments(identifier),
messageOnToken: identifier);
} else {
+ // Use the keyword as the identifier.
parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
return identifier;
}
}
@@ -783,13 +849,13 @@
return identifier;
}
// If not recovered, recover as normal.
- if (!isRecovered || !token.isKeywordOrIdentifier) {
+ if (!isRecovered || !identifier.isKeywordOrIdentifier) {
return ensureIdentifier(token, parser);
}
// If already recovered, use the given token.
parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
return identifier;
}
}
@@ -813,12 +879,16 @@
identifier = parser.insertSyntheticIdentifier(token, this,
message: codes.templateExpectedIdentifier.withArguments(identifier));
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -858,12 +928,16 @@
parser.reportRecoverableErrorWithToken(
identifier, codes.templateBuiltInIdentifierInDeclaration);
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -883,13 +957,13 @@
}
}
// If not recovered, recover as normal.
- if (!isRecovered || !token.isKeywordOrIdentifier) {
+ if (!isRecovered || !identifier.isKeywordOrIdentifier) {
return ensureIdentifier(token, parser);
}
// If already recovered, use the given token.
parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
return identifier;
}
}
@@ -907,7 +981,7 @@
if (identifier.type.isPseudo) {
if (optional('Function', identifier)) {
parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
return identifier;
}
@@ -923,12 +997,16 @@
identifier = parser.insertSyntheticIdentifier(token, this,
message: codes.templateExpectedIdentifier.withArguments(identifier));
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
@@ -942,19 +1020,19 @@
if (identifier.type.isPseudo) {
if (optional('Function', identifier)) {
parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
return identifier;
}
// If not recovered, recover as normal.
- if (!isRecovered || !token.isKeywordOrIdentifier) {
+ if (!isRecovered || !identifier.isKeywordOrIdentifier) {
return ensureIdentifier(token, parser);
}
// If already recovered, use the given token.
parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
return identifier;
}
}
@@ -1045,12 +1123,16 @@
parser.reportRecoverableErrorWithToken(
identifier, codes.templateBuiltInIdentifierInDeclaration);
} else {
- parser.reportRecoverableErrorWithToken(
- identifier, codes.templateExpectedIdentifier);
if (!identifier.isKeywordOrIdentifier) {
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifier);
// When in doubt, consume the token to ensure we make progress
// but insert a synthetic identifier to satisfy listeners.
identifier = parser.rewriter.insertSyntheticIdentifier(identifier);
+ } else {
+ // Use the keyword as the identifier.
+ parser.reportRecoverableErrorWithToken(
+ identifier, codes.templateExpectedIdentifierButGotKeyword);
}
}
return identifier;
diff --git a/pkg/_fe_analyzer_shared/lib/src/parser/parser_impl.dart b/pkg/_fe_analyzer_shared/lib/src/parser/parser_impl.dart
index f7a1317..9c829d4 100644
--- a/pkg/_fe_analyzer_shared/lib/src/parser/parser_impl.dart
+++ b/pkg/_fe_analyzer_shared/lib/src/parser/parser_impl.dart
@@ -6479,6 +6479,8 @@
assert(optional('in', inKeyword) || optional(':', inKeyword));
if (!identifier.isIdentifier) {
+ // TODO(jensj): This should probably (sometimes) be
+ // templateExpectedIdentifierButGotKeyword instead.
reportRecoverableErrorWithToken(
identifier, codes.templateExpectedIdentifier);
} else if (identifier != token) {
diff --git a/pkg/analyzer/lib/error/error.dart b/pkg/analyzer/lib/error/error.dart
index 0d443de..af7ea7b 100644
--- a/pkg/analyzer/lib/error/error.dart
+++ b/pkg/analyzer/lib/error/error.dart
@@ -633,6 +633,7 @@
ParserErrorCode.EXPECTED_CLASS_MEMBER,
ParserErrorCode.EXPECTED_ELSE_OR_COMMA,
ParserErrorCode.EXPECTED_EXECUTABLE,
+ ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD,
ParserErrorCode.EXPECTED_INSTEAD,
ParserErrorCode.EXPECTED_LIST_OR_MAP_LITERAL,
ParserErrorCode.EXPECTED_STRING_LITERAL,
diff --git a/pkg/analyzer/lib/src/dart/error/syntactic_errors.dart b/pkg/analyzer/lib/src/dart/error/syntactic_errors.dart
index f9dd391..b701c7d 100644
--- a/pkg/analyzer/lib/src/dart/error/syntactic_errors.dart
+++ b/pkg/analyzer/lib/src/dart/error/syntactic_errors.dart
@@ -185,6 +185,9 @@
correction:
"This appears to be incomplete code. Try removing it or completing it.");
+ static const ParserErrorCode EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD =
+ _EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD;
+
static const ParserErrorCode EXPECTED_INSTEAD = _EXPECTED_INSTEAD;
static const ParserErrorCode EXPECTED_LIST_OR_MAP_LITERAL = ParserErrorCode(
diff --git a/pkg/analyzer/lib/src/dart/error/syntactic_errors.g.dart b/pkg/analyzer/lib/src/dart/error/syntactic_errors.g.dart
index be1de3a..23291d0 100644
--- a/pkg/analyzer/lib/src/dart/error/syntactic_errors.g.dart
+++ b/pkg/analyzer/lib/src/dart/error/syntactic_errors.g.dart
@@ -120,6 +120,7 @@
_ABSTRACT_EXTERNAL_FIELD,
_ANNOTATION_ON_TYPE_ARGUMENT,
_BINARY_OPERATOR_WRITTEN_OUT,
+ _EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD,
];
const ParserErrorCode _ABSTRACT_CLASS_MEMBER = ParserErrorCode(
@@ -269,6 +270,11 @@
const ParserErrorCode _EXPECTED_ELSE_OR_COMMA =
ParserErrorCode('EXPECTED_ELSE_OR_COMMA', r"Expected 'else' or comma.");
+const ParserErrorCode _EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD = ParserErrorCode(
+ 'EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD',
+ r"'#lexeme' can't be used as an identifier because it's a keyword.",
+ correction: "Try renaming this to be an identifier that isn't a keyword.");
+
const ParserErrorCode _EXPECTED_INSTEAD =
ParserErrorCode('EXPECTED_INSTEAD', r"Expected '#string' instead of this.");
diff --git a/pkg/analyzer/test/generated/parser_fasta_test.dart b/pkg/analyzer/test/generated/parser_fasta_test.dart
index e4b80d0..28b415a 100644
--- a/pkg/analyzer/test/generated/parser_fasta_test.dart
+++ b/pkg/analyzer/test/generated/parser_fasta_test.dart
@@ -1431,7 +1431,7 @@
parseExpression('n=<.["\$assert', errors: [
expectedError(ParserErrorCode.EXPECTED_TYPE_NAME, 3, 1),
expectedError(ParserErrorCode.EXPECTED_TYPE_NAME, 4, 1),
- expectedError(ParserErrorCode.MISSING_IDENTIFIER, 7, 6),
+ expectedError(ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD, 7, 6),
expectedError(ScannerErrorCode.UNTERMINATED_STRING_LITERAL, 12, 1),
expectedError(ScannerErrorCode.EXPECTED_TOKEN, 13, 1),
]);
@@ -1628,8 +1628,9 @@
void test_parseStringLiteral_interpolated_void() {
Expression expression = parseStringLiteral(r"'<html>$void</html>'");
expect(expression, isNotNull);
- assertErrors(
- errors: [expectedError(ParserErrorCode.MISSING_IDENTIFIER, 8, 4)]);
+ assertErrors(errors: [
+ expectedError(ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD, 8, 4)
+ ]);
expect(expression, isStringInterpolation);
StringInterpolation literal = expression;
NodeList<InterpolationElement> elements = literal.elements;
@@ -4898,7 +4899,8 @@
void test_function_disabled() {
parseCompilationUnit('void A(in int value) {}',
errors: [
- expectedError(ParserErrorCode.MISSING_IDENTIFIER, 7, 2),
+ expectedError(
+ ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD, 7, 2),
expectedError(ParserErrorCode.EXPECTED_TOKEN, 10, 3),
],
featureSet: FeatureSet.forTesting(sdkVersion: '2.5.0'));
@@ -4906,7 +4908,7 @@
void test_function_enabled() {
parseCompilationUnit('void A(in int value) {}', errors: [
- expectedError(ParserErrorCode.MISSING_IDENTIFIER, 7, 2),
+ expectedError(ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD, 7, 2),
expectedError(ParserErrorCode.EXPECTED_TOKEN, 10, 3),
]);
}
diff --git a/pkg/analyzer/test/generated/parser_test.dart b/pkg/analyzer/test/generated/parser_test.dart
index 0a08957..3f1b6d7 100644
--- a/pkg/analyzer/test/generated/parser_test.dart
+++ b/pkg/analyzer/test/generated/parser_test.dart
@@ -607,7 +607,10 @@
ClassMember member = parser.parseClassMember('C');
expect(member, isNotNull);
listener.assertErrors(usingFastaParser
- ? [expectedError(ParserErrorCode.MISSING_IDENTIFIER, 4, 3)]
+ ? [
+ expectedError(
+ ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD, 4, 3)
+ ]
: [
expectedError(ParserErrorCode.MISSING_IDENTIFIER, 4, 3),
expectedError(ParserErrorCode.UNEXPECTED_TOKEN, 4, 3)
@@ -3633,7 +3636,8 @@
errors: usingFastaParser
? [
expectedError(ParserErrorCode.EXPECTED_TYPE_NAME, 9, 5),
- expectedError(ParserErrorCode.MISSING_IDENTIFIER, 9, 5)
+ expectedError(
+ ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD, 9, 5)
]
: [expectedError(ParserErrorCode.EXPECTED_TYPE_NAME, 9, 5)]);
}
@@ -3976,7 +3980,8 @@
expectNotNullIfNoErrors(member);
listener.assertErrors([
usingFastaParser
- ? expectedError(ParserErrorCode.MISSING_IDENTIFIER, 2, 4)
+ ? expectedError(
+ ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD, 2, 4)
: expectedError(ParserErrorCode.INVALID_CONSTRUCTOR_NAME, 0, 1)
]);
}
@@ -5453,7 +5458,7 @@
void test_typedef_namedFunction() {
parseCompilationUnit('typedef void Function();',
codes: usingFastaParser
- ? [ParserErrorCode.MISSING_IDENTIFIER]
+ ? [ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD]
: [
ParserErrorCode.UNEXPECTED_TOKEN,
ParserErrorCode.MISSING_IDENTIFIER,
@@ -11347,9 +11352,7 @@
// TODO(brianwilkerson) We could do better with this.
parseCompilationUnit("do() {}",
codes: usingFastaParser
- // fasta reports ExpectedIdentifier
- // which gets mapped to MISSING_IDENTIFIER
- ? [ParserErrorCode.MISSING_IDENTIFIER]
+ ? [ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD]
: [
ParserErrorCode.EXPECTED_EXECUTABLE,
ParserErrorCode.UNEXPECTED_TOKEN
diff --git a/pkg/analyzer/test/src/diagnostics/built_in_identifier_as_typedef_name_test.dart b/pkg/analyzer/test/src/diagnostics/built_in_identifier_as_typedef_name_test.dart
index 7ba99f5..5e344f1 100644
--- a/pkg/analyzer/test/src/diagnostics/built_in_identifier_as_typedef_name_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/built_in_identifier_as_typedef_name_test.dart
@@ -30,7 +30,7 @@
await assertErrorsInCode(r'''
typedef void as();
''', [
- error(ParserErrorCode.MISSING_IDENTIFIER, 13, 2),
+ error(ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD, 13, 2),
error(CompileTimeErrorCode.BUILT_IN_IDENTIFIER_AS_TYPEDEF_NAME, 13, 2),
]);
}
@@ -40,7 +40,7 @@
typedef as = void Function();
''', [
error(CompileTimeErrorCode.BUILT_IN_IDENTIFIER_AS_TYPEDEF_NAME, 8, 2),
- error(ParserErrorCode.MISSING_IDENTIFIER, 8, 2)
+ error(ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD, 8, 2)
]);
}
}
diff --git a/pkg/analyzer/test/src/fasta/recovery/invalid_code_test.dart b/pkg/analyzer/test/src/fasta/recovery/invalid_code_test.dart
index 95b1703..1d0363e 100644
--- a/pkg/analyzer/test/src/fasta/recovery/invalid_code_test.dart
+++ b/pkg/analyzer/test/src/fasta/recovery/invalid_code_test.dart
@@ -29,9 +29,13 @@
void test_default_asVariableName() {
testRecovery('''
const default = const Object();
-''', [ParserErrorCode.MISSING_IDENTIFIER], '''
+''', [
+ ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD
+ ], '''
const default = const Object();
-''', expectedErrorsInValidCode: [ParserErrorCode.MISSING_IDENTIFIER]);
+''', expectedErrorsInValidCode: [
+ ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD
+ ]);
}
void test_expressionInPlaceOfTypeName() {
@@ -82,12 +86,16 @@
g() {
f(with: 3);
}
-''', [ParserErrorCode.MISSING_IDENTIFIER], '''
+''', [
+ ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD
+ ], '''
f() {}
g() {
f(with: 3);
}
-''', expectedErrorsInValidCode: [ParserErrorCode.MISSING_IDENTIFIER]);
+''', expectedErrorsInValidCode: [
+ ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD
+ ]);
}
@failingTest
diff --git a/pkg/front_end/lib/src/fasta/type_inference/type_demotion.dart b/pkg/front_end/lib/src/fasta/type_inference/type_demotion.dart
index a375a55..85bbacd 100644
--- a/pkg/front_end/lib/src/fasta/type_inference/type_demotion.dart
+++ b/pkg/front_end/lib/src/fasta/type_inference/type_demotion.dart
@@ -105,11 +105,11 @@
@override
Nullability visitNullability(DartType node) {
if (forNonNullableByDefault) {
- if (node.nullability == Nullability.legacy) {
+ if (node.declaredNullability == Nullability.legacy) {
return Nullability.nonNullable;
}
} else {
- if (node.nullability != Nullability.legacy) {
+ if (node.declaredNullability != Nullability.legacy) {
return Nullability.legacy;
}
}
diff --git a/pkg/front_end/messages.yaml b/pkg/front_end/messages.yaml
index 618e1fb..c77266e 100644
--- a/pkg/front_end/messages.yaml
+++ b/pkg/front_end/messages.yaml
@@ -494,8 +494,16 @@
ExpectedIdentifier:
template: "Expected an identifier, but got '#lexeme'."
+ tip: "Try inserting an identifier before '#lexeme'."
analyzerCode: MISSING_IDENTIFIER
- script: "do() {} main() {}"
+ script: "var = 42;"
+
+ExpectedIdentifierButGotKeyword:
+ template: "'#lexeme' can't be used as an identifier because it's a keyword."
+ tip: "Try renaming this to be an identifier that isn't a keyword."
+ index: 113
+ analyzerCode: ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD
+ script: "var default = 42;"
EqualityCannotBeEqualityOperand:
index: 1
diff --git a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_00.dart.expect b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_00.dart.expect
index 2331267..0ec0417 100644
--- a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_00.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_00.dart.expect
@@ -41,7 +41,7 @@
handleAsyncModifier(null, null)
beginBlockFunctionBody({)
handleNoTypeArguments([)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., null, {token: ]}], ], ])
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., Try inserting an identifier before ']'., {token: ]}], ], ])
handleIdentifier(, expression)
handleNoTypeArguments(])
handleNoArguments(])
diff --git a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_00.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_00.dart.intertwined.expect
index 51983b2..923a947 100644
--- a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_00.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_00.dart.intertwined.expect
@@ -113,7 +113,7 @@
parseSend((, expression)
ensureIdentifier((, expression)
reportRecoverableErrorWithToken(], Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., null, {token: ]}], ], ])
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., Try inserting an identifier before ']'., {token: ]}], ], ])
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(])
diff --git a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.expect b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.expect
index ce13632..7cd89f8 100644
--- a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.expect
@@ -199,7 +199,7 @@
endArguments(0, (, ))
handleSend(D, ,)
handleRecoverableError(PositionalAfterNamedArgument, ], ])
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., null, {token: ]}], ], ])
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., Try inserting an identifier before ']'., {token: ]}], ], ])
handleIdentifier(, expression)
handleNoTypeArguments(])
handleNoArguments(])
diff --git a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.intertwined.expect
index eb5a793..19fb2c9 100644
--- a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.intertwined.expect
@@ -449,7 +449,7 @@
parseSend(,, expression)
ensureIdentifier(,, expression)
reportRecoverableErrorWithToken(], Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., null, {token: ]}], ], ])
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., Try inserting an identifier before ']'., {token: ]}], ], ])
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(])
diff --git a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_03.dart.expect b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_03.dart.expect
index 8f34cb0..cd7549e 100644
--- a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_03.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_03.dart.expect
@@ -36,7 +36,7 @@
handleSend(foo, ))
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], ), ))
handleExpressionStatement(;)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
diff --git a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_03.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_03.dart.intertwined.expect
index 9828c2f..29aa2f0 100644
--- a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_03.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_03.dart.intertwined.expect
@@ -72,7 +72,7 @@
parseSend(;, expression)
ensureIdentifier(;, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
diff --git a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_04.dart.expect b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_04.dart.expect
index 650a4a0..1afd0ff 100644
--- a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_04.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_04.dart.expect
@@ -44,7 +44,7 @@
handleSend(bar, ))
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], ), ))
handleExpressionStatement(;)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
diff --git a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_04.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_04.dart.intertwined.expect
index 37ece75..16e5973 100644
--- a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_04.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_04.dart.intertwined.expect
@@ -104,7 +104,7 @@
parseSend(;, expression)
ensureIdentifier(;, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
diff --git a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_06.dart.expect b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_06.dart.expect
index 82e783d..9e03ffc 100644
--- a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_06.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_06.dart.expect
@@ -27,7 +27,7 @@
handleNoConstructorReferenceContinuationAfterTypeArguments(()
endConstructorReference(C, null, ()
beginArguments(()
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ';'., null, {token: ;}], ;, ;)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ';'., Try inserting an identifier before ';'., {token: ;}], ;, ;)
handleIdentifier(, expression)
handleNoTypeArguments(;)
handleNoArguments(;)
diff --git a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_06.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_06.dart.intertwined.expect
index e005b6c..b87515d 100644
--- a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_06.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_06.dart.intertwined.expect
@@ -57,7 +57,7 @@
parseSend((, expression)
ensureIdentifier((, expression)
reportRecoverableErrorWithToken(;, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ';'., null, {token: ;}], ;, ;)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ';'., Try inserting an identifier before ';'., {token: ;}], ;, ;)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(;)
diff --git a/pkg/front_end/parser_testcases/error_recovery/empty_await_for.dart.expect b/pkg/front_end/parser_testcases/error_recovery/empty_await_for.dart.expect
index 3c0cebd..ed0f16b 100644
--- a/pkg/front_end/parser_testcases/error_recovery/empty_await_for.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/empty_await_for.dart.expect
@@ -29,16 +29,16 @@
handleAsyncModifier(async, null)
beginBlockFunctionBody({)
beginForStatement(for)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
handleSend(, ))
handleForInitializerExpressionStatement(, true)
handleRecoverableError(Message[ExpectedButGot, Expected 'in' before this., null, {string: in}], ), ))
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
beginForInExpression())
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
diff --git a/pkg/front_end/parser_testcases/error_recovery/empty_await_for.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/empty_await_for.dart.intertwined.expect
index f1c1fcd..e1a476f 100644
--- a/pkg/front_end/parser_testcases/error_recovery/empty_await_for.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/empty_await_for.dart.intertwined.expect
@@ -42,7 +42,7 @@
parseSend((, expression)
ensureIdentifier((, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
@@ -55,7 +55,7 @@
parseForInRest(, await, for, ))
parseForInLoopPartsRest(, await, for, ))
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
listener: beginForInExpression())
parseExpression(in)
parsePrecedenceExpression(in, 1, true)
@@ -64,7 +64,7 @@
parseSend(in, expression)
ensureIdentifier(in, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
diff --git a/pkg/front_end/parser_testcases/error_recovery/empty_for.dart.expect b/pkg/front_end/parser_testcases/error_recovery/empty_for.dart.expect
index 83797a0..3a5b7b2 100644
--- a/pkg/front_end/parser_testcases/error_recovery/empty_for.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/empty_for.dart.expect
@@ -29,14 +29,14 @@
handleAsyncModifier(null, null)
beginBlockFunctionBody({)
beginForStatement(for)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
handleSend(, ))
handleForInitializerExpressionStatement(, false)
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], ), ))
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
diff --git a/pkg/front_end/parser_testcases/error_recovery/empty_for.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/empty_for.dart.intertwined.expect
index c1b40e9..55ccd48 100644
--- a/pkg/front_end/parser_testcases/error_recovery/empty_for.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/empty_for.dart.intertwined.expect
@@ -42,7 +42,7 @@
parseSend((, expression)
ensureIdentifier((, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
@@ -64,7 +64,7 @@
parseSend(;, expression)
ensureIdentifier(;, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39024.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39024.crash_dart.expect
index e4e00d9..6b57708 100644
--- a/pkg/front_end/parser_testcases/error_recovery/issue_39024.crash_dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/issue_39024.crash_dart.expect
@@ -37,7 +37,7 @@
handleRecoverableError(Message[ExpectedAfterButGot, Expected '>' after this., null, {string: >}], S, S)
endTypeArguments(1, <, >)
handleType(n, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ''., null, {token: }], , )
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ''., Try inserting an identifier before ''., {token: }], , )
handleIdentifier(, topLevelFunctionDeclaration)
handleNoTypeVariables()
handleRecoverableError(MissingFunctionParameters, , )
diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39024.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39024.crash_dart.intertwined.expect
index 80d4990..ff3cb76 100644
--- a/pkg/front_end/parser_testcases/error_recovery/issue_39024.crash_dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/issue_39024.crash_dart.intertwined.expect
@@ -21,9 +21,9 @@
listener: endTypeArguments(1, <, >)
listener: handleType(n, null)
ensureIdentifierPotentiallyRecovered(>, topLevelFunctionDeclaration, false)
- insertSyntheticIdentifier(>, topLevelFunctionDeclaration, message: Message[ExpectedIdentifier, Expected an identifier, but got ''., null, {token: }], messageOnToken: null)
- reportRecoverableError(, Message[ExpectedIdentifier, Expected an identifier, but got ''., null, {token: }])
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ''., null, {token: }], , )
+ insertSyntheticIdentifier(>, topLevelFunctionDeclaration, message: Message[ExpectedIdentifier, Expected an identifier, but got ''., Try inserting an identifier before ''., {token: }], messageOnToken: null)
+ reportRecoverableError(, Message[ExpectedIdentifier, Expected an identifier, but got ''., Try inserting an identifier before ''., {token: }])
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ''., Try inserting an identifier before ''., {token: }], , )
rewriter()
listener: handleIdentifier(, topLevelFunctionDeclaration)
parseMethodTypeVar()
diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39202.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39202.crash_dart.expect
index 93bab66..74d4738 100644
--- a/pkg/front_end/parser_testcases/error_recovery/issue_39202.crash_dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/issue_39202.crash_dart.expect
@@ -72,7 +72,7 @@
handleRecoverableError(Message[ExpectedAfterButGot, Expected '>' after this., null, {string: >}], c, c)
endTypeArguments(1, <, >)
handleType(b, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ''., null, {token: }], , )
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ''., Try inserting an identifier before ''., {token: }], , )
handleIdentifier(, topLevelVariableDeclaration)
handleNoFieldInitializer()
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], , )
diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39202.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39202.crash_dart.intertwined.expect
index e188e74..ee3b3ec 100644
--- a/pkg/front_end/parser_testcases/error_recovery/issue_39202.crash_dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/issue_39202.crash_dart.intertwined.expect
@@ -88,9 +88,9 @@
listener: endTypeArguments(1, <, >)
listener: handleType(b, null)
ensureIdentifierPotentiallyRecovered(>, topLevelVariableDeclaration, false)
- insertSyntheticIdentifier(>, topLevelVariableDeclaration, message: Message[ExpectedIdentifier, Expected an identifier, but got ''., null, {token: }], messageOnToken: null)
- reportRecoverableError(, Message[ExpectedIdentifier, Expected an identifier, but got ''., null, {token: }])
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ''., null, {token: }], , )
+ insertSyntheticIdentifier(>, topLevelVariableDeclaration, message: Message[ExpectedIdentifier, Expected an identifier, but got ''., Try inserting an identifier before ''., {token: }], messageOnToken: null)
+ reportRecoverableError(, Message[ExpectedIdentifier, Expected an identifier, but got ''., Try inserting an identifier before ''., {token: }])
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ''., Try inserting an identifier before ''., {token: }], , )
rewriter()
listener: handleIdentifier(, topLevelVariableDeclaration)
parseFieldInitializerOpt(, , null, null, null, null, DeclarationKind.TopLevel, null)
diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_42267.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_42267.dart.expect
index b2c79c1..705b02f 100644
--- a/pkg/front_end/parser_testcases/error_recovery/issue_42267.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/issue_42267.dart.expect
@@ -91,7 +91,7 @@
handleNoArguments([])
handleSend(foo, [])
handleEndingBinaryExpression(..)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., null, {token: ]}], ], ])
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., Try inserting an identifier before ']'., {token: ]}], ], ])
handleIdentifier(, expression)
handleNoTypeArguments(])
handleNoArguments(])
@@ -124,7 +124,7 @@
handleNoArguments([])
handleSend(foo, [])
handleEndingBinaryExpression(..)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., null, {token: ]}], ], ])
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., Try inserting an identifier before ']'., {token: ]}], ], ])
handleIdentifier(, expression)
handleNoTypeArguments(])
handleNoArguments(])
@@ -146,7 +146,7 @@
handleNoArguments([)
handleSend(foo, [)
handleEndingBinaryExpression(..)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., null, {token: ]}], ], ])
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., Try inserting an identifier before ']'., {token: ]}], ], ])
handleIdentifier(, expression)
handleNoTypeArguments(])
handleNoArguments(])
@@ -179,7 +179,7 @@
handleNoArguments([)
handleSend(foo, [)
handleEndingBinaryExpression(..)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., null, {token: ]}], ], ])
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., Try inserting an identifier before ']'., {token: ]}], ], ])
handleIdentifier(, expression)
handleNoTypeArguments(])
handleNoArguments(])
diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_42267.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_42267.dart.intertwined.expect
index 1a76870..9b81d3a 100644
--- a/pkg/front_end/parser_testcases/error_recovery/issue_42267.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/issue_42267.dart.intertwined.expect
@@ -203,7 +203,7 @@
parseSend([, expression)
ensureIdentifier([, expression)
reportRecoverableErrorWithToken(], Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., null, {token: ]}], ], ])
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., Try inserting an identifier before ']'., {token: ]}], ], ])
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(])
@@ -296,7 +296,7 @@
parseSend([, expression)
ensureIdentifier([, expression)
reportRecoverableErrorWithToken(], Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., null, {token: ]}], ], ])
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., Try inserting an identifier before ']'., {token: ]}], ], ])
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(])
@@ -349,7 +349,7 @@
parseSend([, expression)
ensureIdentifier([, expression)
reportRecoverableErrorWithToken(], Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., null, {token: ]}], ], ])
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., Try inserting an identifier before ']'., {token: ]}], ], ])
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(])
@@ -439,7 +439,7 @@
parseSend([, expression)
ensureIdentifier([, expression)
reportRecoverableErrorWithToken(], Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., null, {token: ]}], ], ])
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ']'., Try inserting an identifier before ']'., {token: ]}], ], ])
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(])
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.expect
index d552dbc..9919798 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.expect
@@ -1,134 +1,134 @@
Problems reported:
-parser/error_recovery/keyword_named_class_fields:4:7: Expected an identifier, but got 'assert'.
+parser/error_recovery/keyword_named_class_fields:4:7: 'assert' can't be used as an identifier because it's a keyword.
int assert = 42;
^^^^^^
-parser/error_recovery/keyword_named_class_fields:7:7: Expected an identifier, but got 'break'.
+parser/error_recovery/keyword_named_class_fields:7:7: 'break' can't be used as an identifier because it's a keyword.
int break = 42;
^^^^^
-parser/error_recovery/keyword_named_class_fields:8:7: Expected an identifier, but got 'case'.
+parser/error_recovery/keyword_named_class_fields:8:7: 'case' can't be used as an identifier because it's a keyword.
int case = 42;
^^^^
-parser/error_recovery/keyword_named_class_fields:9:7: Expected an identifier, but got 'catch'.
+parser/error_recovery/keyword_named_class_fields:9:7: 'catch' can't be used as an identifier because it's a keyword.
int catch = 42;
^^^^^
-parser/error_recovery/keyword_named_class_fields:10:7: Expected an identifier, but got 'class'.
+parser/error_recovery/keyword_named_class_fields:10:7: 'class' can't be used as an identifier because it's a keyword.
int class = 42;
^^^^^
-parser/error_recovery/keyword_named_class_fields:11:7: Expected an identifier, but got 'const'.
+parser/error_recovery/keyword_named_class_fields:11:7: 'const' can't be used as an identifier because it's a keyword.
int const = 42;
^^^^^
-parser/error_recovery/keyword_named_class_fields:12:7: Expected an identifier, but got 'continue'.
+parser/error_recovery/keyword_named_class_fields:12:7: 'continue' can't be used as an identifier because it's a keyword.
int continue = 42;
^^^^^^^^
-parser/error_recovery/keyword_named_class_fields:14:7: Expected an identifier, but got 'default'.
+parser/error_recovery/keyword_named_class_fields:14:7: 'default' can't be used as an identifier because it's a keyword.
int default = 42;
^^^^^^^
-parser/error_recovery/keyword_named_class_fields:16:7: Expected an identifier, but got 'do'.
+parser/error_recovery/keyword_named_class_fields:16:7: 'do' can't be used as an identifier because it's a keyword.
int do = 42;
^^
-parser/error_recovery/keyword_named_class_fields:18:7: Expected an identifier, but got 'else'.
+parser/error_recovery/keyword_named_class_fields:18:7: 'else' can't be used as an identifier because it's a keyword.
int else = 42;
^^^^
-parser/error_recovery/keyword_named_class_fields:19:7: Expected an identifier, but got 'enum'.
+parser/error_recovery/keyword_named_class_fields:19:7: 'enum' can't be used as an identifier because it's a keyword.
int enum = 42;
^^^^
-parser/error_recovery/keyword_named_class_fields:21:7: Expected an identifier, but got 'extends'.
+parser/error_recovery/keyword_named_class_fields:21:7: 'extends' can't be used as an identifier because it's a keyword.
int extends = 42;
^^^^^^^
-parser/error_recovery/keyword_named_class_fields:25:7: Expected an identifier, but got 'false'.
+parser/error_recovery/keyword_named_class_fields:25:7: 'false' can't be used as an identifier because it's a keyword.
int false = 42;
^^^^^
-parser/error_recovery/keyword_named_class_fields:26:7: Expected an identifier, but got 'final'.
+parser/error_recovery/keyword_named_class_fields:26:7: 'final' can't be used as an identifier because it's a keyword.
int final = 42;
^^^^^
-parser/error_recovery/keyword_named_class_fields:27:7: Expected an identifier, but got 'finally'.
+parser/error_recovery/keyword_named_class_fields:27:7: 'finally' can't be used as an identifier because it's a keyword.
int finally = 42;
^^^^^^^
-parser/error_recovery/keyword_named_class_fields:28:7: Expected an identifier, but got 'for'.
+parser/error_recovery/keyword_named_class_fields:28:7: 'for' can't be used as an identifier because it's a keyword.
int for = 42;
^^^
-parser/error_recovery/keyword_named_class_fields:32:7: Expected an identifier, but got 'if'.
+parser/error_recovery/keyword_named_class_fields:32:7: 'if' can't be used as an identifier because it's a keyword.
int if = 42;
^^
-parser/error_recovery/keyword_named_class_fields:35:7: Expected an identifier, but got 'in'.
+parser/error_recovery/keyword_named_class_fields:35:7: 'in' can't be used as an identifier because it's a keyword.
int in = 42;
^^
-parser/error_recovery/keyword_named_class_fields:38:7: Expected an identifier, but got 'is'.
+parser/error_recovery/keyword_named_class_fields:38:7: 'is' can't be used as an identifier because it's a keyword.
int is = 42;
^^
-parser/error_recovery/keyword_named_class_fields:43:7: Expected an identifier, but got 'new'.
+parser/error_recovery/keyword_named_class_fields:43:7: 'new' can't be used as an identifier because it's a keyword.
int new = 42;
^^^
-parser/error_recovery/keyword_named_class_fields:44:7: Expected an identifier, but got 'null'.
+parser/error_recovery/keyword_named_class_fields:44:7: 'null' can't be used as an identifier because it's a keyword.
int null = 42;
^^^^
-parser/error_recovery/keyword_named_class_fields:52:7: Expected an identifier, but got 'rethrow'.
+parser/error_recovery/keyword_named_class_fields:52:7: 'rethrow' can't be used as an identifier because it's a keyword.
int rethrow = 42;
^^^^^^^
-parser/error_recovery/keyword_named_class_fields:53:7: Expected an identifier, but got 'return'.
+parser/error_recovery/keyword_named_class_fields:53:7: 'return' can't be used as an identifier because it's a keyword.
int return = 42;
^^^^^^
-parser/error_recovery/keyword_named_class_fields:58:7: Expected an identifier, but got 'super'.
+parser/error_recovery/keyword_named_class_fields:58:7: 'super' can't be used as an identifier because it's a keyword.
int super = 42;
^^^^^
-parser/error_recovery/keyword_named_class_fields:59:7: Expected an identifier, but got 'switch'.
+parser/error_recovery/keyword_named_class_fields:59:7: 'switch' can't be used as an identifier because it's a keyword.
int switch = 42;
^^^^^^
-parser/error_recovery/keyword_named_class_fields:61:7: Expected an identifier, but got 'this'.
+parser/error_recovery/keyword_named_class_fields:61:7: 'this' can't be used as an identifier because it's a keyword.
int this = 42;
^^^^
-parser/error_recovery/keyword_named_class_fields:62:7: Expected an identifier, but got 'throw'.
+parser/error_recovery/keyword_named_class_fields:62:7: 'throw' can't be used as an identifier because it's a keyword.
int throw = 42;
^^^^^
-parser/error_recovery/keyword_named_class_fields:63:7: Expected an identifier, but got 'true'.
+parser/error_recovery/keyword_named_class_fields:63:7: 'true' can't be used as an identifier because it's a keyword.
int true = 42;
^^^^
-parser/error_recovery/keyword_named_class_fields:64:7: Expected an identifier, but got 'try'.
+parser/error_recovery/keyword_named_class_fields:64:7: 'try' can't be used as an identifier because it's a keyword.
int try = 42;
^^^
-parser/error_recovery/keyword_named_class_fields:66:7: Expected an identifier, but got 'var'.
+parser/error_recovery/keyword_named_class_fields:66:7: 'var' can't be used as an identifier because it's a keyword.
int var = 42;
^^^
-parser/error_recovery/keyword_named_class_fields:67:7: Expected an identifier, but got 'void'.
+parser/error_recovery/keyword_named_class_fields:67:7: 'void' can't be used as an identifier because it's a keyword.
int void = 42;
^^^^
-parser/error_recovery/keyword_named_class_fields:68:7: Expected an identifier, but got 'while'.
+parser/error_recovery/keyword_named_class_fields:68:7: 'while' can't be used as an identifier because it's a keyword.
int while = 42;
^^^^^
-parser/error_recovery/keyword_named_class_fields:69:7: Expected an identifier, but got 'with'.
+parser/error_recovery/keyword_named_class_fields:69:7: 'with' can't be used as an identifier because it's a keyword.
int with = 42;
^^^^
@@ -178,7 +178,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(assert)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'assert'., null, {token: assert}], assert, assert)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'assert' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: assert}], assert, assert)
handleIdentifier(assert, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -218,7 +218,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(break)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'break' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: break}], break, break)
handleIdentifier(break, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -232,7 +232,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(case)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
handleIdentifier(case, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -246,7 +246,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(catch)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
handleIdentifier(catch, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -260,7 +260,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(class)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
handleIdentifier(class, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -274,7 +274,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(const)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'const'., null, {token: const}], const, const)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'const' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: const}], const, const)
handleIdentifier(const, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -288,7 +288,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(continue)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'continue' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: continue}], continue, continue)
handleIdentifier(continue, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -315,7 +315,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(default)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
handleIdentifier(default, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -342,7 +342,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(do)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'do' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: do}], do, do)
handleIdentifier(do, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -369,7 +369,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(else)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'else' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: else}], else, else)
handleIdentifier(else, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -383,7 +383,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(enum)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
handleIdentifier(enum, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -410,7 +410,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(extends)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
handleIdentifier(extends, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -463,7 +463,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(false)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'false'., null, {token: false}], false, false)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'false' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: false}], false, false)
handleIdentifier(false, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -477,7 +477,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(final)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'final' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: final}], final, final)
handleIdentifier(final, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -491,7 +491,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(finally)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
handleIdentifier(finally, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -505,7 +505,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(for)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'for' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: for}], for, for)
handleIdentifier(for, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -558,7 +558,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(if)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'if' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: if}], if, if)
handleIdentifier(if, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -598,7 +598,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(in)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
handleIdentifier(in, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -638,7 +638,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(is)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'is' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: is}], is, is)
handleIdentifier(is, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -704,7 +704,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(new)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'new'., null, {token: new}], new, new)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'new' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: new}], new, new)
handleIdentifier(new, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -718,7 +718,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(null)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'null'., null, {token: null}], null, null)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'null' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: null}], null, null)
handleIdentifier(null, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -823,7 +823,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(rethrow)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
handleIdentifier(rethrow, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -837,7 +837,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(return)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'return'., null, {token: return}], return, return)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'return' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: return}], return, return)
handleIdentifier(return, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -903,7 +903,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(super)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'super'., null, {token: super}], super, super)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'super' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: super}], super, super)
handleIdentifier(super, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -917,7 +917,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(switch)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'switch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: switch}], switch, switch)
handleIdentifier(switch, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -944,7 +944,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(this)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'this' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: this}], this, this)
handleIdentifier(this, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -958,7 +958,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(throw)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'throw'., null, {token: throw}], throw, throw)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'throw' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: throw}], throw, throw)
handleIdentifier(throw, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -972,7 +972,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(true)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'true'., null, {token: true}], true, true)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'true' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: true}], true, true)
handleIdentifier(true, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -986,7 +986,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(try)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'try' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: try}], try, try)
handleIdentifier(try, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -1013,7 +1013,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(var)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'var' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: var}], var, var)
handleIdentifier(var, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -1027,7 +1027,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(void)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'void' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: void}], void, void)
handleIdentifier(void, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -1041,7 +1041,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(while)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'while' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: while}], while, while)
handleIdentifier(while, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -1055,7 +1055,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(with)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
handleIdentifier(with, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.intertwined.expect
index 467d656..ef8682d 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.intertwined.expect
@@ -89,7 +89,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(assert, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'assert'., null, {token: assert}], assert, assert)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'assert' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: assert}], assert, assert)
listener: handleIdentifier(assert, fieldDeclaration)
parseFieldInitializerOpt(assert, assert, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -165,7 +165,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(break, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'break' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: break}], break, break)
listener: handleIdentifier(break, fieldDeclaration)
parseFieldInitializerOpt(break, break, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -193,7 +193,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(case, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
listener: handleIdentifier(case, fieldDeclaration)
parseFieldInitializerOpt(case, case, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -221,7 +221,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(catch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
listener: handleIdentifier(catch, fieldDeclaration)
parseFieldInitializerOpt(catch, catch, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -249,7 +249,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(class, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
listener: handleIdentifier(class, fieldDeclaration)
parseFieldInitializerOpt(class, class, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -277,7 +277,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(const, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'const'., null, {token: const}], const, const)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'const' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: const}], const, const)
listener: handleIdentifier(const, fieldDeclaration)
parseFieldInitializerOpt(const, const, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -305,7 +305,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(continue, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'continue' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: continue}], continue, continue)
listener: handleIdentifier(continue, fieldDeclaration)
parseFieldInitializerOpt(continue, continue, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -357,7 +357,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(default, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
listener: handleIdentifier(default, fieldDeclaration)
parseFieldInitializerOpt(default, default, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -409,7 +409,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(do, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'do' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: do}], do, do)
listener: handleIdentifier(do, fieldDeclaration)
parseFieldInitializerOpt(do, do, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -461,7 +461,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(else, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'else' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: else}], else, else)
listener: handleIdentifier(else, fieldDeclaration)
parseFieldInitializerOpt(else, else, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -489,7 +489,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(enum, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
listener: handleIdentifier(enum, fieldDeclaration)
parseFieldInitializerOpt(enum, enum, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -541,7 +541,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(extends, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
listener: handleIdentifier(extends, fieldDeclaration)
parseFieldInitializerOpt(extends, extends, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -641,7 +641,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(false, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'false'., null, {token: false}], false, false)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'false' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: false}], false, false)
listener: handleIdentifier(false, fieldDeclaration)
parseFieldInitializerOpt(false, false, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -669,7 +669,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(final, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'final' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: final}], final, final)
listener: handleIdentifier(final, fieldDeclaration)
parseFieldInitializerOpt(final, final, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -697,7 +697,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(finally, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
listener: handleIdentifier(finally, fieldDeclaration)
parseFieldInitializerOpt(finally, finally, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -725,7 +725,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(for, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'for' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: for}], for, for)
listener: handleIdentifier(for, fieldDeclaration)
parseFieldInitializerOpt(for, for, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -826,7 +826,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(if, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'if' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: if}], if, if)
listener: handleIdentifier(if, fieldDeclaration)
parseFieldInitializerOpt(if, if, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -902,7 +902,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(in, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
listener: handleIdentifier(in, fieldDeclaration)
parseFieldInitializerOpt(in, in, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -978,7 +978,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(is, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'is' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: is}], is, is)
listener: handleIdentifier(is, fieldDeclaration)
parseFieldInitializerOpt(is, is, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -1102,7 +1102,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(new, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'new'., null, {token: new}], new, new)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'new' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: new}], new, new)
listener: handleIdentifier(new, fieldDeclaration)
parseFieldInitializerOpt(new, new, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -1130,7 +1130,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(null, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'null'., null, {token: null}], null, null)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'null' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: null}], null, null)
listener: handleIdentifier(null, fieldDeclaration)
parseFieldInitializerOpt(null, null, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -1327,7 +1327,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(rethrow, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
listener: handleIdentifier(rethrow, fieldDeclaration)
parseFieldInitializerOpt(rethrow, rethrow, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -1355,7 +1355,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(return, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'return'., null, {token: return}], return, return)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'return' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: return}], return, return)
listener: handleIdentifier(return, fieldDeclaration)
parseFieldInitializerOpt(return, return, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -1480,7 +1480,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(super, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'super'., null, {token: super}], super, super)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'super' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: super}], super, super)
listener: handleIdentifier(super, fieldDeclaration)
parseFieldInitializerOpt(super, super, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -1508,7 +1508,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(switch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'switch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: switch}], switch, switch)
listener: handleIdentifier(switch, fieldDeclaration)
parseFieldInitializerOpt(switch, switch, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -1559,7 +1559,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
reportRecoverableErrorWithToken(this, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'this' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: this}], this, this)
listener: handleIdentifier(this, fieldDeclaration)
parseFieldInitializerOpt(this, this, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -1587,7 +1587,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(throw, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'throw'., null, {token: throw}], throw, throw)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'throw' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: throw}], throw, throw)
listener: handleIdentifier(throw, fieldDeclaration)
parseFieldInitializerOpt(throw, throw, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -1615,7 +1615,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(true, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'true'., null, {token: true}], true, true)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'true' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: true}], true, true)
listener: handleIdentifier(true, fieldDeclaration)
parseFieldInitializerOpt(true, true, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -1643,7 +1643,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(try, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'try' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: try}], try, try)
listener: handleIdentifier(try, fieldDeclaration)
parseFieldInitializerOpt(try, try, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -1695,7 +1695,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(var, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'var' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: var}], var, var)
listener: handleIdentifier(var, fieldDeclaration)
parseFieldInitializerOpt(var, var, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -1723,7 +1723,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(void, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'void' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: void}], void, void)
listener: handleIdentifier(void, fieldDeclaration)
parseFieldInitializerOpt(void, void, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -1751,7 +1751,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(while, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'while' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: while}], while, while)
listener: handleIdentifier(while, fieldDeclaration)
parseFieldInitializerOpt(while, while, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
@@ -1779,7 +1779,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
listener: handleIdentifier(with, fieldDeclaration)
parseFieldInitializerOpt(with, with, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: beginFieldInitializer(=)
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.expect
index 614bc0c..c3ffe0e 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.expect
@@ -1,6 +1,6 @@
Problems reported:
-parser/error_recovery/keyword_named_class_methods:12:7: Expected an identifier, but got 'assert'.
+parser/error_recovery/keyword_named_class_methods:12:7: 'assert' can't be used as an identifier because it's a keyword.
int assert(int x) {
^^^^^^
@@ -8,7 +8,7 @@
return assert(x-1) + 1;
^^^^^^
-parser/error_recovery/keyword_named_class_methods:27:7: Expected an identifier, but got 'break'.
+parser/error_recovery/keyword_named_class_methods:27:7: 'break' can't be used as an identifier because it's a keyword.
int break(int x) {
^^^^^
@@ -28,31 +28,31 @@
return break(x-1) + 1;
^^^^^
-parser/error_recovery/keyword_named_class_methods:32:7: Expected an identifier, but got 'case'.
+parser/error_recovery/keyword_named_class_methods:32:7: 'case' can't be used as an identifier because it's a keyword.
int case(int x) {
^^^^
-parser/error_recovery/keyword_named_class_methods:34:12: Expected an identifier, but got 'case'.
+parser/error_recovery/keyword_named_class_methods:34:12: 'case' can't be used as an identifier because it's a keyword.
return case(x-1) + 1;
^^^^
-parser/error_recovery/keyword_named_class_methods:37:7: Expected an identifier, but got 'catch'.
+parser/error_recovery/keyword_named_class_methods:37:7: 'catch' can't be used as an identifier because it's a keyword.
int catch(int x) {
^^^^^
-parser/error_recovery/keyword_named_class_methods:39:12: Expected an identifier, but got 'catch'.
+parser/error_recovery/keyword_named_class_methods:39:12: 'catch' can't be used as an identifier because it's a keyword.
return catch(x-1) + 1;
^^^^^
-parser/error_recovery/keyword_named_class_methods:42:7: Expected an identifier, but got 'class'.
+parser/error_recovery/keyword_named_class_methods:42:7: 'class' can't be used as an identifier because it's a keyword.
int class(int x) {
^^^^^
-parser/error_recovery/keyword_named_class_methods:44:12: Expected an identifier, but got 'class'.
+parser/error_recovery/keyword_named_class_methods:44:12: 'class' can't be used as an identifier because it's a keyword.
return class(x-1) + 1;
^^^^^
-parser/error_recovery/keyword_named_class_methods:47:7: Expected an identifier, but got 'const'.
+parser/error_recovery/keyword_named_class_methods:47:7: 'const' can't be used as an identifier because it's a keyword.
int const(int x) {
^^^^^
@@ -60,7 +60,7 @@
return const(x-1) + 1;
^
-parser/error_recovery/keyword_named_class_methods:52:7: Expected an identifier, but got 'continue'.
+parser/error_recovery/keyword_named_class_methods:52:7: 'continue' can't be used as an identifier because it's a keyword.
int continue(int x) {
^^^^^^^^
@@ -80,15 +80,15 @@
return continue(x-1) + 1;
^^^^^^^^
-parser/error_recovery/keyword_named_class_methods:62:7: Expected an identifier, but got 'default'.
+parser/error_recovery/keyword_named_class_methods:62:7: 'default' can't be used as an identifier because it's a keyword.
int default(int x) {
^^^^^^^
-parser/error_recovery/keyword_named_class_methods:64:12: Expected an identifier, but got 'default'.
+parser/error_recovery/keyword_named_class_methods:64:12: 'default' can't be used as an identifier because it's a keyword.
return default(x-1) + 1;
^^^^^^^
-parser/error_recovery/keyword_named_class_methods:72:7: Expected an identifier, but got 'do'.
+parser/error_recovery/keyword_named_class_methods:72:7: 'do' can't be used as an identifier because it's a keyword.
int do(int x) {
^^
@@ -116,7 +116,7 @@
}
^
-parser/error_recovery/keyword_named_class_methods:82:7: Expected an identifier, but got 'else'.
+parser/error_recovery/keyword_named_class_methods:82:7: 'else' can't be used as an identifier because it's a keyword.
int else(int x) {
^^^^
@@ -140,27 +140,27 @@
return else(x-1) + 1;
^^^^
-parser/error_recovery/keyword_named_class_methods:87:7: Expected an identifier, but got 'enum'.
+parser/error_recovery/keyword_named_class_methods:87:7: 'enum' can't be used as an identifier because it's a keyword.
int enum(int x) {
^^^^
-parser/error_recovery/keyword_named_class_methods:89:12: Expected an identifier, but got 'enum'.
+parser/error_recovery/keyword_named_class_methods:89:12: 'enum' can't be used as an identifier because it's a keyword.
return enum(x-1) + 1;
^^^^
-parser/error_recovery/keyword_named_class_methods:97:7: Expected an identifier, but got 'extends'.
+parser/error_recovery/keyword_named_class_methods:97:7: 'extends' can't be used as an identifier because it's a keyword.
int extends(int x) {
^^^^^^^
-parser/error_recovery/keyword_named_class_methods:99:12: Expected an identifier, but got 'extends'.
+parser/error_recovery/keyword_named_class_methods:99:12: 'extends' can't be used as an identifier because it's a keyword.
return extends(x-1) + 1;
^^^^^^^
-parser/error_recovery/keyword_named_class_methods:117:7: Expected an identifier, but got 'false'.
+parser/error_recovery/keyword_named_class_methods:117:7: 'false' can't be used as an identifier because it's a keyword.
int false(int x) {
^^^^^
-parser/error_recovery/keyword_named_class_methods:122:7: Expected an identifier, but got 'final'.
+parser/error_recovery/keyword_named_class_methods:122:7: 'final' can't be used as an identifier because it's a keyword.
int final(int x) {
^^^^^
@@ -200,15 +200,15 @@
return final(x-1) + 1;
^
-parser/error_recovery/keyword_named_class_methods:127:7: Expected an identifier, but got 'finally'.
+parser/error_recovery/keyword_named_class_methods:127:7: 'finally' can't be used as an identifier because it's a keyword.
int finally(int x) {
^^^^^^^
-parser/error_recovery/keyword_named_class_methods:129:12: Expected an identifier, but got 'finally'.
+parser/error_recovery/keyword_named_class_methods:129:12: 'finally' can't be used as an identifier because it's a keyword.
return finally(x-1) + 1;
^^^^^^^
-parser/error_recovery/keyword_named_class_methods:132:7: Expected an identifier, but got 'for'.
+parser/error_recovery/keyword_named_class_methods:132:7: 'for' can't be used as an identifier because it's a keyword.
int for(int x) {
^^^
@@ -236,7 +236,7 @@
return for(x-1) + 1;
^
-parser/error_recovery/keyword_named_class_methods:152:7: Expected an identifier, but got 'if'.
+parser/error_recovery/keyword_named_class_methods:152:7: 'if' can't be used as an identifier because it's a keyword.
int if(int x) {
^^
@@ -252,15 +252,15 @@
return if(x-1) + 1;
^
-parser/error_recovery/keyword_named_class_methods:167:7: Expected an identifier, but got 'in'.
+parser/error_recovery/keyword_named_class_methods:167:7: 'in' can't be used as an identifier because it's a keyword.
int in(int x) {
^^
-parser/error_recovery/keyword_named_class_methods:169:12: Expected an identifier, but got 'in'.
+parser/error_recovery/keyword_named_class_methods:169:12: 'in' can't be used as an identifier because it's a keyword.
return in(x-1) + 1;
^^
-parser/error_recovery/keyword_named_class_methods:182:7: Expected an identifier, but got 'is'.
+parser/error_recovery/keyword_named_class_methods:182:7: 'is' can't be used as an identifier because it's a keyword.
int is(int x) {
^^
@@ -276,7 +276,7 @@
return is(x-1) + 1;
^
-parser/error_recovery/keyword_named_class_methods:207:7: Expected an identifier, but got 'new'.
+parser/error_recovery/keyword_named_class_methods:207:7: 'new' can't be used as an identifier because it's a keyword.
int new(int x) {
^^^
@@ -284,19 +284,19 @@
return new(x-1) + 1;
^
-parser/error_recovery/keyword_named_class_methods:212:7: Expected an identifier, but got 'null'.
+parser/error_recovery/keyword_named_class_methods:212:7: 'null' can't be used as an identifier because it's a keyword.
int null(int x) {
^^^^
-parser/error_recovery/keyword_named_class_methods:252:7: Expected an identifier, but got 'rethrow'.
+parser/error_recovery/keyword_named_class_methods:252:7: 'rethrow' can't be used as an identifier because it's a keyword.
int rethrow(int x) {
^^^^^^^
-parser/error_recovery/keyword_named_class_methods:254:12: Expected an identifier, but got 'rethrow'.
+parser/error_recovery/keyword_named_class_methods:254:12: 'rethrow' can't be used as an identifier because it's a keyword.
return rethrow(x-1) + 1;
^^^^^^^
-parser/error_recovery/keyword_named_class_methods:257:7: Expected an identifier, but got 'return'.
+parser/error_recovery/keyword_named_class_methods:257:7: 'return' can't be used as an identifier because it's a keyword.
int return(int x) {
^^^^^^
@@ -304,11 +304,11 @@
return return(x-1) + 1;
^^^^^^
-parser/error_recovery/keyword_named_class_methods:282:7: Expected an identifier, but got 'super'.
+parser/error_recovery/keyword_named_class_methods:282:7: 'super' can't be used as an identifier because it's a keyword.
int super(int x) {
^^^^^
-parser/error_recovery/keyword_named_class_methods:287:7: Expected an identifier, but got 'switch'.
+parser/error_recovery/keyword_named_class_methods:287:7: 'switch' can't be used as an identifier because it's a keyword.
int switch(int x) {
^^^^^^
@@ -328,7 +328,7 @@
return switch(x-1) + 1;
^
-parser/error_recovery/keyword_named_class_methods:297:7: Expected an identifier, but got 'this'.
+parser/error_recovery/keyword_named_class_methods:297:7: 'this' can't be used as an identifier because it's a keyword.
int this(int x) {
^^^^
@@ -340,15 +340,15 @@
int this(int x) {
^
-parser/error_recovery/keyword_named_class_methods:302:7: Expected an identifier, but got 'throw'.
+parser/error_recovery/keyword_named_class_methods:302:7: 'throw' can't be used as an identifier because it's a keyword.
int throw(int x) {
^^^^^
-parser/error_recovery/keyword_named_class_methods:307:7: Expected an identifier, but got 'true'.
+parser/error_recovery/keyword_named_class_methods:307:7: 'true' can't be used as an identifier because it's a keyword.
int true(int x) {
^^^^
-parser/error_recovery/keyword_named_class_methods:312:7: Expected an identifier, but got 'try'.
+parser/error_recovery/keyword_named_class_methods:312:7: 'try' can't be used as an identifier because it's a keyword.
int try(int x) {
^^^
@@ -368,7 +368,7 @@
return try(x-1) + 1;
^^^
-parser/error_recovery/keyword_named_class_methods:322:7: Expected an identifier, but got 'var'.
+parser/error_recovery/keyword_named_class_methods:322:7: 'var' can't be used as an identifier because it's a keyword.
int var(int x) {
^^^
@@ -408,7 +408,7 @@
return var(x-1) + 1;
^
-parser/error_recovery/keyword_named_class_methods:327:7: Expected an identifier, but got 'void'.
+parser/error_recovery/keyword_named_class_methods:327:7: 'void' can't be used as an identifier because it's a keyword.
int void(int x) {
^^^^
@@ -448,7 +448,7 @@
return void(x-1) + 1;
^
-parser/error_recovery/keyword_named_class_methods:332:7: Expected an identifier, but got 'while'.
+parser/error_recovery/keyword_named_class_methods:332:7: 'while' can't be used as an identifier because it's a keyword.
int while(int x) {
^^^^^
@@ -464,11 +464,11 @@
return while(x-1) + 1;
^
-parser/error_recovery/keyword_named_class_methods:337:7: Expected an identifier, but got 'with'.
+parser/error_recovery/keyword_named_class_methods:337:7: 'with' can't be used as an identifier because it's a keyword.
int with(int x) {
^^^^
-parser/error_recovery/keyword_named_class_methods:339:12: Expected an identifier, but got 'with'.
+parser/error_recovery/keyword_named_class_methods:339:12: 'with' can't be used as an identifier because it's a keyword.
return with(x-1) + 1;
^^^^
@@ -608,7 +608,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(assert)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'assert'., null, {token: assert}], assert, assert)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'assert' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: assert}], assert, assert)
handleIdentifier(assert, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -781,7 +781,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(break)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'break' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: break}], break, break)
handleIdentifier(break, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -814,7 +814,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., Try inserting an identifier before 'break'., {token: break}], break, break)
handleIdentifier(, expression)
handleNoTypeArguments(break)
handleNoArguments(break)
@@ -846,7 +846,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(case)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
handleIdentifier(case, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -879,7 +879,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
handleIdentifier(case, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -906,7 +906,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(catch)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
handleIdentifier(catch, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -939,7 +939,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
handleIdentifier(catch, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -966,7 +966,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(class)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
handleIdentifier(class, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -999,7 +999,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
handleIdentifier(class, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -1026,7 +1026,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(const)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'const'., null, {token: const}], const, const)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'const' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: const}], const, const)
handleIdentifier(const, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -1060,7 +1060,7 @@
endIfStatement(if, null)
beginReturnStatement(return)
beginConstExpression(const)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
handleIdentifier(, constructorReference)
beginConstructorReference()
handleNoTypeArguments(()
@@ -1090,7 +1090,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(continue)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'continue' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: continue}], continue, continue)
handleIdentifier(continue, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -1123,7 +1123,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., Try inserting an identifier before 'continue'., {token: continue}], continue, continue)
handleIdentifier(, expression)
handleNoTypeArguments(continue)
handleNoArguments(continue)
@@ -1213,7 +1213,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(default)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
handleIdentifier(default, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -1246,7 +1246,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
handleIdentifier(default, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -1331,7 +1331,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(do)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'do' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: do}], do, do)
handleIdentifier(do, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -1364,7 +1364,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., Try inserting an identifier before 'do'., {token: do}], do, do)
handleIdentifier(, expression)
handleNoTypeArguments(do)
handleNoArguments(do)
@@ -1388,7 +1388,7 @@
endDoWhileStatementBody(;)
handleRecoverableError(Message[ExpectedButGot, Expected 'while' before this., null, {string: while}], }, })
handleRecoverableError(Message[ExpectedToken, Expected to find '('., null, {string: (}], }, })
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '}'., null, {token: }}], }, })
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '}'., Try inserting an identifier before '}'., {token: }}], }, })
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
@@ -1464,7 +1464,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(else)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'else' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: else}], else, else)
handleIdentifier(else, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -1497,14 +1497,14 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., Try inserting an identifier before 'else'., {token: else}], else, else)
handleIdentifier(, expression)
handleNoTypeArguments(else)
handleNoArguments(else)
handleSend(, else)
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], else, else)
endReturnStatement(true, return, ;)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., Try inserting an identifier before 'else'., {token: else}], else, else)
handleIdentifier(, expression)
handleNoTypeArguments(else)
handleNoArguments(else)
@@ -1534,7 +1534,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(enum)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
handleIdentifier(enum, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -1567,7 +1567,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
handleIdentifier(enum, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -1652,7 +1652,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(extends)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
handleIdentifier(extends, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -1685,7 +1685,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
handleIdentifier(extends, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -1886,7 +1886,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(false)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'false'., null, {token: false}], false, false)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'false' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: false}], false, false)
handleIdentifier(false, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -1945,7 +1945,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(final)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'final' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: final}], final, final)
handleIdentifier(final, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -1978,7 +1978,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., Try inserting an identifier before 'final'., {token: final}], final, final)
handleIdentifier(, expression)
handleNoTypeArguments(final)
handleNoArguments(final)
@@ -1989,7 +1989,7 @@
endMetadataStar(0)
handleNoType(final)
beginVariablesDeclaration((, null, final)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
handleIdentifier(, localVariableDeclaration)
beginInitializedIdentifier()
handleNoVariableInitializer()
@@ -2005,7 +2005,7 @@
endBinaryExpression(-)
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], 1, 1)
handleExpressionStatement(;)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
@@ -2032,7 +2032,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(finally)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
handleIdentifier(finally, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -2065,7 +2065,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
handleIdentifier(finally, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -2092,7 +2092,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(for)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'for' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: for}], for, for)
handleIdentifier(for, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -2125,7 +2125,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., Try inserting an identifier before 'for'., {token: for}], for, for)
handleIdentifier(, expression)
handleNoTypeArguments(for)
handleNoArguments(for)
@@ -2142,7 +2142,7 @@
endBinaryExpression(-)
handleForInitializerExpressionStatement(1, false)
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], 1, 1)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
@@ -2346,7 +2346,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(if)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'if' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: if}], if, if)
handleIdentifier(if, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -2379,7 +2379,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., Try inserting an identifier before 'if'., {token: if}], if, if)
handleIdentifier(, expression)
handleNoTypeArguments(if)
handleNoArguments(if)
@@ -2533,7 +2533,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(in)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
handleIdentifier(in, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -2566,7 +2566,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
handleIdentifier(in, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -2709,7 +2709,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(is)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'is' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: is}], is, is)
handleIdentifier(is, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -2742,7 +2742,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., Try inserting an identifier before 'is'., {token: is}], is, is)
handleIdentifier(, expression)
handleNoTypeArguments(is)
handleNoArguments(is)
@@ -3010,7 +3010,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(new)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'new'., null, {token: new}], new, new)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'new' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: new}], new, new)
handleIdentifier(new, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -3044,7 +3044,7 @@
endIfStatement(if, null)
beginReturnStatement(return)
beginNewExpression(new)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
handleIdentifier(, constructorReference)
beginConstructorReference()
handleNoTypeArguments(()
@@ -3074,7 +3074,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(null)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'null'., null, {token: null}], null, null)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'null' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: null}], null, null)
handleIdentifier(null, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -3539,7 +3539,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(rethrow)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
handleIdentifier(rethrow, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -3572,7 +3572,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
handleIdentifier(rethrow, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -3599,7 +3599,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(return)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'return'., null, {token: return}], return, return)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'return' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: return}], return, return)
handleIdentifier(return, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -3887,7 +3887,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(super)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'super'., null, {token: super}], super, super)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'super' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: super}], super, super)
handleIdentifier(super, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -3946,7 +3946,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(switch)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'switch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: switch}], switch, switch)
handleIdentifier(switch, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -3979,7 +3979,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., Try inserting an identifier before 'switch'., {token: switch}], switch, switch)
handleIdentifier(, expression)
handleNoTypeArguments(switch)
handleNoArguments(switch)
@@ -4076,7 +4076,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(this)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'this' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: this}], this, this)
handleIdentifier(this, fieldDeclaration)
handleNoFieldInitializer(()
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], this, this)
@@ -4087,7 +4087,7 @@
beginMember()
beginMethod(null, null, null, null, null, ()
handleNoType(;)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
handleIdentifier(, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -4146,7 +4146,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(throw)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'throw'., null, {token: throw}], throw, throw)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'throw' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: throw}], throw, throw)
handleIdentifier(throw, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -4202,7 +4202,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(true)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'true'., null, {token: true}], true, true)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'true' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: true}], true, true)
handleIdentifier(true, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -4261,7 +4261,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(try)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'try' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: try}], try, try)
handleIdentifier(try, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -4294,7 +4294,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., Try inserting an identifier before 'try'., {token: try}], try, try)
handleIdentifier(, expression)
handleNoTypeArguments(try)
handleNoArguments(try)
@@ -4387,7 +4387,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(var)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'var' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: var}], var, var)
handleIdentifier(var, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -4420,7 +4420,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., Try inserting an identifier before 'var'., {token: var}], var, var)
handleIdentifier(, expression)
handleNoTypeArguments(var)
handleNoArguments(var)
@@ -4431,7 +4431,7 @@
endMetadataStar(0)
handleNoType(var)
beginVariablesDeclaration((, null, var)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
handleIdentifier(, localVariableDeclaration)
beginInitializedIdentifier()
handleNoVariableInitializer()
@@ -4447,7 +4447,7 @@
endBinaryExpression(-)
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], 1, 1)
handleExpressionStatement(;)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
@@ -4474,7 +4474,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(void)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'void' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: void}], void, void)
handleIdentifier(void, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -4507,7 +4507,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., Try inserting an identifier before 'void'., {token: void}], void, void)
handleIdentifier(, expression)
handleNoTypeArguments(void)
handleNoArguments(void)
@@ -4518,7 +4518,7 @@
endMetadataStar(0)
handleVoidKeyword(void)
beginVariablesDeclaration((, null, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
handleIdentifier(, localVariableDeclaration)
beginInitializedIdentifier()
handleNoVariableInitializer()
@@ -4534,7 +4534,7 @@
endBinaryExpression(-)
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], 1, 1)
handleExpressionStatement(;)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
@@ -4561,7 +4561,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(while)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'while' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: while}], while, while)
handleIdentifier(while, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -4594,7 +4594,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., Try inserting an identifier before 'while'., {token: while}], while, while)
handleIdentifier(, expression)
handleNoTypeArguments(while)
handleNoArguments(while)
@@ -4632,7 +4632,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(with)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
handleIdentifier(with, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -4665,7 +4665,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
handleIdentifier(with, expression)
handleNoTypeArguments(()
beginArguments(()
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.intertwined.expect
index 325c75e..bfd0eb21 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.intertwined.expect
@@ -323,7 +323,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(assert, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'assert'., null, {token: assert}], assert, assert)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'assert' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: assert}], assert, assert)
listener: handleIdentifier(assert, methodDeclaration)
parseQualifiedRestOpt(assert, methodDeclarationContinuation)
parseMethodTypeVar(assert)
@@ -745,7 +745,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(break, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'break' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: break}], break, break)
listener: handleIdentifier(break, methodDeclaration)
parseQualifiedRestOpt(break, methodDeclarationContinuation)
parseMethodTypeVar(break)
@@ -832,7 +832,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(break, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., Try inserting an identifier before 'break'., {token: break}], break, break)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(break)
@@ -921,7 +921,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(case, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
listener: handleIdentifier(case, methodDeclaration)
parseQualifiedRestOpt(case, methodDeclarationContinuation)
parseMethodTypeVar(case)
@@ -1008,7 +1008,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(case, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
listener: handleIdentifier(case, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(case)
@@ -1065,7 +1065,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(catch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
listener: handleIdentifier(catch, methodDeclaration)
parseQualifiedRestOpt(catch, methodDeclarationContinuation)
parseMethodTypeVar(catch)
@@ -1152,7 +1152,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(catch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
listener: handleIdentifier(catch, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(catch)
@@ -1209,7 +1209,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(class, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
listener: handleIdentifier(class, methodDeclaration)
parseQualifiedRestOpt(class, methodDeclarationContinuation)
parseMethodTypeVar(class)
@@ -1296,7 +1296,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(class, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
listener: handleIdentifier(class, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(class)
@@ -1353,7 +1353,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(const, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'const'., null, {token: const}], const, const)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'const' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: const}], const, const)
listener: handleIdentifier(const, methodDeclaration)
parseQualifiedRestOpt(const, methodDeclarationContinuation)
parseMethodTypeVar(const)
@@ -1440,9 +1440,9 @@
listener: beginConstExpression(const)
parseConstructorReference(const, null)
ensureIdentifier(const, constructorReference)
- insertSyntheticIdentifier(const, constructorReference, message: Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], messageOnToken: null)
- reportRecoverableError((, Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}])
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ insertSyntheticIdentifier(const, constructorReference, message: Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], messageOnToken: null)
+ reportRecoverableError((, Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}])
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
rewriter()
listener: handleIdentifier(, constructorReference)
listener: beginConstructorReference()
@@ -1503,7 +1503,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(continue, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'continue' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: continue}], continue, continue)
listener: handleIdentifier(continue, methodDeclaration)
parseQualifiedRestOpt(continue, methodDeclarationContinuation)
parseMethodTypeVar(continue)
@@ -1590,7 +1590,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(continue, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., Try inserting an identifier before 'continue'., {token: continue}], continue, continue)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(continue)
@@ -1820,7 +1820,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(default, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
listener: handleIdentifier(default, methodDeclaration)
parseQualifiedRestOpt(default, methodDeclarationContinuation)
parseMethodTypeVar(default)
@@ -1907,7 +1907,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(default, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
listener: handleIdentifier(default, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(default)
@@ -2105,7 +2105,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(do, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'do' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: do}], do, do)
listener: handleIdentifier(do, methodDeclaration)
parseQualifiedRestOpt(do, methodDeclarationContinuation)
parseMethodTypeVar(do)
@@ -2192,7 +2192,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(do, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., Try inserting an identifier before 'do'., {token: do}], do, do)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(do)
@@ -2271,7 +2271,7 @@
parseSend((, expression)
ensureIdentifier((, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '}'., null, {token: }}], }, })
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '}'., Try inserting an identifier before '}'., {token: }}], }, })
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
@@ -2445,7 +2445,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(else, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'else' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: else}], else, else)
listener: handleIdentifier(else, methodDeclaration)
parseQualifiedRestOpt(else, methodDeclarationContinuation)
parseMethodTypeVar(else)
@@ -2532,7 +2532,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(else, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., Try inserting an identifier before 'else'., {token: else}], else, else)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(else)
@@ -2560,7 +2560,7 @@
parseSend(;, expression)
ensureIdentifier(;, expression)
reportRecoverableErrorWithToken(else, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., Try inserting an identifier before 'else'., {token: else}], else, else)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(else)
@@ -2638,7 +2638,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(enum, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
listener: handleIdentifier(enum, methodDeclaration)
parseQualifiedRestOpt(enum, methodDeclarationContinuation)
parseMethodTypeVar(enum)
@@ -2725,7 +2725,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(enum, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
listener: handleIdentifier(enum, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(enum)
@@ -2923,7 +2923,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(extends, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
listener: handleIdentifier(extends, methodDeclaration)
parseQualifiedRestOpt(extends, methodDeclarationContinuation)
parseMethodTypeVar(extends)
@@ -3010,7 +3010,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(extends, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
listener: handleIdentifier(extends, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(extends)
@@ -3490,7 +3490,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(false, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'false'., null, {token: false}], false, false)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'false' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: false}], false, false)
listener: handleIdentifier(false, methodDeclaration)
parseQualifiedRestOpt(false, methodDeclarationContinuation)
parseMethodTypeVar(false)
@@ -3630,7 +3630,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(final, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'final' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: final}], final, final)
listener: handleIdentifier(final, methodDeclaration)
parseQualifiedRestOpt(final, methodDeclarationContinuation)
parseMethodTypeVar(final)
@@ -3717,7 +3717,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(final, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., Try inserting an identifier before 'final'., {token: final}], final, final)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(final)
@@ -3743,7 +3743,7 @@
parseOptionallyInitializedIdentifier(final)
ensureIdentifier(final, localVariableDeclaration)
reportRecoverableErrorWithToken((, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
rewriter()
listener: handleIdentifier(, localVariableDeclaration)
listener: beginInitializedIdentifier()
@@ -3799,7 +3799,7 @@
parseSend(;, expression)
ensureIdentifier(;, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
@@ -3864,7 +3864,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(finally, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
listener: handleIdentifier(finally, methodDeclaration)
parseQualifiedRestOpt(finally, methodDeclarationContinuation)
parseMethodTypeVar(finally)
@@ -3951,7 +3951,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(finally, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
listener: handleIdentifier(finally, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(finally)
@@ -4008,7 +4008,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(for, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'for' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: for}], for, for)
listener: handleIdentifier(for, methodDeclaration)
parseQualifiedRestOpt(for, methodDeclarationContinuation)
parseMethodTypeVar(for)
@@ -4095,7 +4095,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(for, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., Try inserting an identifier before 'for'., {token: for}], for, for)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(for)
@@ -4151,7 +4151,7 @@
parseSend(;, expression)
ensureIdentifier(;, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
@@ -4641,7 +4641,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(if, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'if' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: if}], if, if)
listener: handleIdentifier(if, methodDeclaration)
parseQualifiedRestOpt(if, methodDeclarationContinuation)
parseMethodTypeVar(if)
@@ -4728,7 +4728,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(if, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., Try inserting an identifier before 'if'., {token: if}], if, if)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(if)
@@ -5104,7 +5104,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(in, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
listener: handleIdentifier(in, methodDeclaration)
parseQualifiedRestOpt(in, methodDeclarationContinuation)
parseMethodTypeVar(in)
@@ -5191,7 +5191,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(in, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
listener: handleIdentifier(in, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(in)
@@ -5530,7 +5530,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(is, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'is' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: is}], is, is)
listener: handleIdentifier(is, methodDeclaration)
parseQualifiedRestOpt(is, methodDeclarationContinuation)
parseMethodTypeVar(is)
@@ -5617,7 +5617,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(is, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., Try inserting an identifier before 'is'., {token: is}], is, is)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(is)
@@ -6270,7 +6270,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(new, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'new'., null, {token: new}], new, new)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'new' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: new}], new, new)
listener: handleIdentifier(new, methodDeclaration)
parseQualifiedRestOpt(new, methodDeclarationContinuation)
parseMethodTypeVar(new)
@@ -6357,9 +6357,9 @@
listener: beginNewExpression(new)
parseConstructorReference(new, null)
ensureIdentifier(new, constructorReference)
- insertSyntheticIdentifier(new, constructorReference, message: Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], messageOnToken: null)
- reportRecoverableError((, Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}])
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ insertSyntheticIdentifier(new, constructorReference, message: Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], messageOnToken: null)
+ reportRecoverableError((, Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}])
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
rewriter()
listener: handleIdentifier(, constructorReference)
listener: beginConstructorReference()
@@ -6420,7 +6420,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(null, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'null'., null, {token: null}], null, null)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'null' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: null}], null, null)
listener: handleIdentifier(null, methodDeclaration)
parseQualifiedRestOpt(null, methodDeclarationContinuation)
parseMethodTypeVar(null)
@@ -7549,7 +7549,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(rethrow, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
listener: handleIdentifier(rethrow, methodDeclaration)
parseQualifiedRestOpt(rethrow, methodDeclarationContinuation)
parseMethodTypeVar(rethrow)
@@ -7636,7 +7636,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(rethrow, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
listener: handleIdentifier(rethrow, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(rethrow)
@@ -7693,7 +7693,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(return, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'return'., null, {token: return}], return, return)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'return' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: return}], return, return)
listener: handleIdentifier(return, methodDeclaration)
parseQualifiedRestOpt(return, methodDeclarationContinuation)
parseMethodTypeVar(return)
@@ -8399,7 +8399,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(super, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'super'., null, {token: super}], super, super)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'super' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: super}], super, super)
listener: handleIdentifier(super, methodDeclaration)
parseQualifiedRestOpt(super, methodDeclarationContinuation)
parseMethodTypeVar(super)
@@ -8538,7 +8538,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(switch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'switch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: switch}], switch, switch)
listener: handleIdentifier(switch, methodDeclaration)
parseQualifiedRestOpt(switch, methodDeclarationContinuation)
parseMethodTypeVar(switch)
@@ -8625,7 +8625,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(switch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., Try inserting an identifier before 'switch'., {token: switch}], switch, switch)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(switch)
@@ -8868,7 +8868,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
reportRecoverableErrorWithToken(this, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'this' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: this}], this, this)
listener: handleIdentifier(this, fieldDeclaration)
parseFieldInitializerOpt(this, this, null, null, null, null, DeclarationKind.Class, WrapperClass)
listener: handleNoFieldInitializer(()
@@ -8890,8 +8890,8 @@
listener: handleNoType(;)
ensureIdentifierPotentiallyRecovered(;, methodDeclaration, false)
insertSyntheticIdentifier(;, methodDeclaration, message: null, messageOnToken: null)
- reportRecoverableError((, Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}])
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ reportRecoverableError((, Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}])
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
rewriter()
listener: handleIdentifier(, methodDeclaration)
parseQualifiedRestOpt(, methodDeclarationContinuation)
@@ -9031,7 +9031,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(throw, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'throw'., null, {token: throw}], throw, throw)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'throw' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: throw}], throw, throw)
listener: handleIdentifier(throw, methodDeclaration)
parseQualifiedRestOpt(throw, methodDeclarationContinuation)
parseMethodTypeVar(throw)
@@ -9171,7 +9171,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(true, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'true'., null, {token: true}], true, true)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'true' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: true}], true, true)
listener: handleIdentifier(true, methodDeclaration)
parseQualifiedRestOpt(true, methodDeclarationContinuation)
parseMethodTypeVar(true)
@@ -9311,7 +9311,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(try, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'try' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: try}], try, try)
listener: handleIdentifier(try, methodDeclaration)
parseQualifiedRestOpt(try, methodDeclarationContinuation)
parseMethodTypeVar(try)
@@ -9398,7 +9398,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(try, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., Try inserting an identifier before 'try'., {token: try}], try, try)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(try)
@@ -9634,7 +9634,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(var, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'var' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: var}], var, var)
listener: handleIdentifier(var, methodDeclaration)
parseQualifiedRestOpt(var, methodDeclarationContinuation)
parseMethodTypeVar(var)
@@ -9721,7 +9721,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(var, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., Try inserting an identifier before 'var'., {token: var}], var, var)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(var)
@@ -9747,7 +9747,7 @@
parseOptionallyInitializedIdentifier(var)
ensureIdentifier(var, localVariableDeclaration)
reportRecoverableErrorWithToken((, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
rewriter()
listener: handleIdentifier(, localVariableDeclaration)
listener: beginInitializedIdentifier()
@@ -9803,7 +9803,7 @@
parseSend(;, expression)
ensureIdentifier(;, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
@@ -9868,7 +9868,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(void, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'void' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: void}], void, void)
listener: handleIdentifier(void, methodDeclaration)
parseQualifiedRestOpt(void, methodDeclarationContinuation)
parseMethodTypeVar(void)
@@ -9955,7 +9955,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(void, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., Try inserting an identifier before 'void'., {token: void}], void, void)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(void)
@@ -9982,7 +9982,7 @@
parseOptionallyInitializedIdentifier(void)
ensureIdentifier(void, localVariableDeclaration)
reportRecoverableErrorWithToken((, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
rewriter()
listener: handleIdentifier(, localVariableDeclaration)
listener: beginInitializedIdentifier()
@@ -10038,7 +10038,7 @@
parseSend(;, expression)
ensureIdentifier(;, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
@@ -10103,7 +10103,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(while, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'while' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: while}], while, while)
listener: handleIdentifier(while, methodDeclaration)
parseQualifiedRestOpt(while, methodDeclarationContinuation)
parseMethodTypeVar(while)
@@ -10190,7 +10190,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(while, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., Try inserting an identifier before 'while'., {token: while}], while, while)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(while)
@@ -10284,7 +10284,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
listener: handleIdentifier(with, methodDeclaration)
parseQualifiedRestOpt(with, methodDeclarationContinuation)
parseMethodTypeVar(with)
@@ -10371,7 +10371,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
listener: handleIdentifier(with, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(with)
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_fields.dart.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_fields.dart.expect
index 7789ff7..c634476 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_fields.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_fields.dart.expect
@@ -1,134 +1,134 @@
Problems reported:
-parser/error_recovery/keyword_named_top_level_fields:3:5: Expected an identifier, but got 'assert'.
+parser/error_recovery/keyword_named_top_level_fields:3:5: 'assert' can't be used as an identifier because it's a keyword.
int assert = 42;
^^^^^^
-parser/error_recovery/keyword_named_top_level_fields:6:5: Expected an identifier, but got 'break'.
+parser/error_recovery/keyword_named_top_level_fields:6:5: 'break' can't be used as an identifier because it's a keyword.
int break = 42;
^^^^^
-parser/error_recovery/keyword_named_top_level_fields:7:5: Expected an identifier, but got 'case'.
+parser/error_recovery/keyword_named_top_level_fields:7:5: 'case' can't be used as an identifier because it's a keyword.
int case = 42;
^^^^
-parser/error_recovery/keyword_named_top_level_fields:8:5: Expected an identifier, but got 'catch'.
+parser/error_recovery/keyword_named_top_level_fields:8:5: 'catch' can't be used as an identifier because it's a keyword.
int catch = 42;
^^^^^
-parser/error_recovery/keyword_named_top_level_fields:9:5: Expected an identifier, but got 'class'.
+parser/error_recovery/keyword_named_top_level_fields:9:5: 'class' can't be used as an identifier because it's a keyword.
int class = 42;
^^^^^
-parser/error_recovery/keyword_named_top_level_fields:10:5: Expected an identifier, but got 'const'.
+parser/error_recovery/keyword_named_top_level_fields:10:5: 'const' can't be used as an identifier because it's a keyword.
int const = 42;
^^^^^
-parser/error_recovery/keyword_named_top_level_fields:11:5: Expected an identifier, but got 'continue'.
+parser/error_recovery/keyword_named_top_level_fields:11:5: 'continue' can't be used as an identifier because it's a keyword.
int continue = 42;
^^^^^^^^
-parser/error_recovery/keyword_named_top_level_fields:13:5: Expected an identifier, but got 'default'.
+parser/error_recovery/keyword_named_top_level_fields:13:5: 'default' can't be used as an identifier because it's a keyword.
int default = 42;
^^^^^^^
-parser/error_recovery/keyword_named_top_level_fields:15:5: Expected an identifier, but got 'do'.
+parser/error_recovery/keyword_named_top_level_fields:15:5: 'do' can't be used as an identifier because it's a keyword.
int do = 42;
^^
-parser/error_recovery/keyword_named_top_level_fields:17:5: Expected an identifier, but got 'else'.
+parser/error_recovery/keyword_named_top_level_fields:17:5: 'else' can't be used as an identifier because it's a keyword.
int else = 42;
^^^^
-parser/error_recovery/keyword_named_top_level_fields:18:5: Expected an identifier, but got 'enum'.
+parser/error_recovery/keyword_named_top_level_fields:18:5: 'enum' can't be used as an identifier because it's a keyword.
int enum = 42;
^^^^
-parser/error_recovery/keyword_named_top_level_fields:20:5: Expected an identifier, but got 'extends'.
+parser/error_recovery/keyword_named_top_level_fields:20:5: 'extends' can't be used as an identifier because it's a keyword.
int extends = 42;
^^^^^^^
-parser/error_recovery/keyword_named_top_level_fields:24:5: Expected an identifier, but got 'false'.
+parser/error_recovery/keyword_named_top_level_fields:24:5: 'false' can't be used as an identifier because it's a keyword.
int false = 42;
^^^^^
-parser/error_recovery/keyword_named_top_level_fields:25:5: Expected an identifier, but got 'final'.
+parser/error_recovery/keyword_named_top_level_fields:25:5: 'final' can't be used as an identifier because it's a keyword.
int final = 42;
^^^^^
-parser/error_recovery/keyword_named_top_level_fields:26:5: Expected an identifier, but got 'finally'.
+parser/error_recovery/keyword_named_top_level_fields:26:5: 'finally' can't be used as an identifier because it's a keyword.
int finally = 42;
^^^^^^^
-parser/error_recovery/keyword_named_top_level_fields:27:5: Expected an identifier, but got 'for'.
+parser/error_recovery/keyword_named_top_level_fields:27:5: 'for' can't be used as an identifier because it's a keyword.
int for = 42;
^^^
-parser/error_recovery/keyword_named_top_level_fields:31:5: Expected an identifier, but got 'if'.
+parser/error_recovery/keyword_named_top_level_fields:31:5: 'if' can't be used as an identifier because it's a keyword.
int if = 42;
^^
-parser/error_recovery/keyword_named_top_level_fields:34:5: Expected an identifier, but got 'in'.
+parser/error_recovery/keyword_named_top_level_fields:34:5: 'in' can't be used as an identifier because it's a keyword.
int in = 42;
^^
-parser/error_recovery/keyword_named_top_level_fields:37:5: Expected an identifier, but got 'is'.
+parser/error_recovery/keyword_named_top_level_fields:37:5: 'is' can't be used as an identifier because it's a keyword.
int is = 42;
^^
-parser/error_recovery/keyword_named_top_level_fields:42:5: Expected an identifier, but got 'new'.
+parser/error_recovery/keyword_named_top_level_fields:42:5: 'new' can't be used as an identifier because it's a keyword.
int new = 42;
^^^
-parser/error_recovery/keyword_named_top_level_fields:43:5: Expected an identifier, but got 'null'.
+parser/error_recovery/keyword_named_top_level_fields:43:5: 'null' can't be used as an identifier because it's a keyword.
int null = 42;
^^^^
-parser/error_recovery/keyword_named_top_level_fields:51:5: Expected an identifier, but got 'rethrow'.
+parser/error_recovery/keyword_named_top_level_fields:51:5: 'rethrow' can't be used as an identifier because it's a keyword.
int rethrow = 42;
^^^^^^^
-parser/error_recovery/keyword_named_top_level_fields:52:5: Expected an identifier, but got 'return'.
+parser/error_recovery/keyword_named_top_level_fields:52:5: 'return' can't be used as an identifier because it's a keyword.
int return = 42;
^^^^^^
-parser/error_recovery/keyword_named_top_level_fields:57:5: Expected an identifier, but got 'super'.
+parser/error_recovery/keyword_named_top_level_fields:57:5: 'super' can't be used as an identifier because it's a keyword.
int super = 42;
^^^^^
-parser/error_recovery/keyword_named_top_level_fields:58:5: Expected an identifier, but got 'switch'.
+parser/error_recovery/keyword_named_top_level_fields:58:5: 'switch' can't be used as an identifier because it's a keyword.
int switch = 42;
^^^^^^
-parser/error_recovery/keyword_named_top_level_fields:60:5: Expected an identifier, but got 'this'.
+parser/error_recovery/keyword_named_top_level_fields:60:5: 'this' can't be used as an identifier because it's a keyword.
int this = 42;
^^^^
-parser/error_recovery/keyword_named_top_level_fields:61:5: Expected an identifier, but got 'throw'.
+parser/error_recovery/keyword_named_top_level_fields:61:5: 'throw' can't be used as an identifier because it's a keyword.
int throw = 42;
^^^^^
-parser/error_recovery/keyword_named_top_level_fields:62:5: Expected an identifier, but got 'true'.
+parser/error_recovery/keyword_named_top_level_fields:62:5: 'true' can't be used as an identifier because it's a keyword.
int true = 42;
^^^^
-parser/error_recovery/keyword_named_top_level_fields:63:5: Expected an identifier, but got 'try'.
+parser/error_recovery/keyword_named_top_level_fields:63:5: 'try' can't be used as an identifier because it's a keyword.
int try = 42;
^^^
-parser/error_recovery/keyword_named_top_level_fields:65:5: Expected an identifier, but got 'var'.
+parser/error_recovery/keyword_named_top_level_fields:65:5: 'var' can't be used as an identifier because it's a keyword.
int var = 42;
^^^
-parser/error_recovery/keyword_named_top_level_fields:66:5: Expected an identifier, but got 'void'.
+parser/error_recovery/keyword_named_top_level_fields:66:5: 'void' can't be used as an identifier because it's a keyword.
int void = 42;
^^^^
-parser/error_recovery/keyword_named_top_level_fields:67:5: Expected an identifier, but got 'while'.
+parser/error_recovery/keyword_named_top_level_fields:67:5: 'while' can't be used as an identifier because it's a keyword.
int while = 42;
^^^^^
-parser/error_recovery/keyword_named_top_level_fields:68:5: Expected an identifier, but got 'with'.
+parser/error_recovery/keyword_named_top_level_fields:68:5: 'with' can't be used as an identifier because it's a keyword.
int with = 42;
^^^^
@@ -166,7 +166,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(assert)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'assert'., null, {token: assert}], assert, assert)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'assert' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: assert}], assert, assert)
handleIdentifier(assert, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -206,7 +206,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(break)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'break' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: break}], break, break)
handleIdentifier(break, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -220,7 +220,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(case)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
handleIdentifier(case, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -234,7 +234,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(catch)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
handleIdentifier(catch, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -248,7 +248,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(class)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
handleIdentifier(class, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -262,7 +262,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(const)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'const'., null, {token: const}], const, const)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'const' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: const}], const, const)
handleIdentifier(const, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -276,7 +276,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(continue)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'continue' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: continue}], continue, continue)
handleIdentifier(continue, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -303,7 +303,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(default)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
handleIdentifier(default, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -330,7 +330,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(do)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'do' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: do}], do, do)
handleIdentifier(do, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -357,7 +357,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(else)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'else' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: else}], else, else)
handleIdentifier(else, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -371,7 +371,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(enum)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
handleIdentifier(enum, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -398,7 +398,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(extends)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
handleIdentifier(extends, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -451,7 +451,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(false)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'false'., null, {token: false}], false, false)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'false' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: false}], false, false)
handleIdentifier(false, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -465,7 +465,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(final)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'final' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: final}], final, final)
handleIdentifier(final, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -479,7 +479,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(finally)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
handleIdentifier(finally, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -493,7 +493,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(for)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'for' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: for}], for, for)
handleIdentifier(for, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -546,7 +546,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(if)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'if' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: if}], if, if)
handleIdentifier(if, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -586,7 +586,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(in)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
handleIdentifier(in, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -626,7 +626,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(is)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'is' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: is}], is, is)
handleIdentifier(is, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -692,7 +692,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(new)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'new'., null, {token: new}], new, new)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'new' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: new}], new, new)
handleIdentifier(new, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -706,7 +706,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(null)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'null'., null, {token: null}], null, null)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'null' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: null}], null, null)
handleIdentifier(null, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -811,7 +811,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(rethrow)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
handleIdentifier(rethrow, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -825,7 +825,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(return)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'return'., null, {token: return}], return, return)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'return' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: return}], return, return)
handleIdentifier(return, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -891,7 +891,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(super)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'super'., null, {token: super}], super, super)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'super' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: super}], super, super)
handleIdentifier(super, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -905,7 +905,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(switch)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'switch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: switch}], switch, switch)
handleIdentifier(switch, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -932,7 +932,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(this)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'this' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: this}], this, this)
handleIdentifier(this, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -946,7 +946,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(throw)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'throw'., null, {token: throw}], throw, throw)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'throw' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: throw}], throw, throw)
handleIdentifier(throw, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -960,7 +960,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(true)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'true'., null, {token: true}], true, true)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'true' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: true}], true, true)
handleIdentifier(true, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -974,7 +974,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(try)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'try' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: try}], try, try)
handleIdentifier(try, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -1001,7 +1001,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(var)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'var' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: var}], var, var)
handleIdentifier(var, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -1015,7 +1015,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(void)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'void' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: void}], void, void)
handleIdentifier(void, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -1029,7 +1029,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(while)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'while' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: while}], while, while)
handleIdentifier(while, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
@@ -1043,7 +1043,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(with)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
handleIdentifier(with, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(42)
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_fields.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_fields.dart.intertwined.expect
index fc69737..b6db767 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_fields.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_fields.dart.intertwined.expect
@@ -65,7 +65,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(assert, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'assert'., null, {token: assert}], assert, assert)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'assert' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: assert}], assert, assert)
listener: handleIdentifier(assert, topLevelVariableDeclaration)
parseFieldInitializerOpt(assert, assert, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -141,7 +141,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(break, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'break' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: break}], break, break)
listener: handleIdentifier(break, topLevelVariableDeclaration)
parseFieldInitializerOpt(break, break, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -169,7 +169,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(case, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
listener: handleIdentifier(case, topLevelVariableDeclaration)
parseFieldInitializerOpt(case, case, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -197,7 +197,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(catch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
listener: handleIdentifier(catch, topLevelVariableDeclaration)
parseFieldInitializerOpt(catch, catch, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -225,7 +225,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(class, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
listener: handleIdentifier(class, topLevelVariableDeclaration)
parseFieldInitializerOpt(class, class, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -253,7 +253,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(const, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'const'., null, {token: const}], const, const)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'const' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: const}], const, const)
listener: handleIdentifier(const, topLevelVariableDeclaration)
parseFieldInitializerOpt(const, const, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -281,7 +281,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(continue, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'continue' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: continue}], continue, continue)
listener: handleIdentifier(continue, topLevelVariableDeclaration)
parseFieldInitializerOpt(continue, continue, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -333,7 +333,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(default, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
listener: handleIdentifier(default, topLevelVariableDeclaration)
parseFieldInitializerOpt(default, default, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -385,7 +385,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(do, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'do' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: do}], do, do)
listener: handleIdentifier(do, topLevelVariableDeclaration)
parseFieldInitializerOpt(do, do, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -437,7 +437,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(else, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'else' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: else}], else, else)
listener: handleIdentifier(else, topLevelVariableDeclaration)
parseFieldInitializerOpt(else, else, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -465,7 +465,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(enum, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
listener: handleIdentifier(enum, topLevelVariableDeclaration)
parseFieldInitializerOpt(enum, enum, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -517,7 +517,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(extends, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
listener: handleIdentifier(extends, topLevelVariableDeclaration)
parseFieldInitializerOpt(extends, extends, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -617,7 +617,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(false, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'false'., null, {token: false}], false, false)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'false' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: false}], false, false)
listener: handleIdentifier(false, topLevelVariableDeclaration)
parseFieldInitializerOpt(false, false, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -645,7 +645,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(final, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'final' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: final}], final, final)
listener: handleIdentifier(final, topLevelVariableDeclaration)
parseFieldInitializerOpt(final, final, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -673,7 +673,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(finally, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
listener: handleIdentifier(finally, topLevelVariableDeclaration)
parseFieldInitializerOpt(finally, finally, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -701,7 +701,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(for, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'for' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: for}], for, for)
listener: handleIdentifier(for, topLevelVariableDeclaration)
parseFieldInitializerOpt(for, for, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -801,7 +801,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(if, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'if' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: if}], if, if)
listener: handleIdentifier(if, topLevelVariableDeclaration)
parseFieldInitializerOpt(if, if, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -877,7 +877,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(in, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
listener: handleIdentifier(in, topLevelVariableDeclaration)
parseFieldInitializerOpt(in, in, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -953,7 +953,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(is, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'is' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: is}], is, is)
listener: handleIdentifier(is, topLevelVariableDeclaration)
parseFieldInitializerOpt(is, is, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -1077,7 +1077,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(new, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'new'., null, {token: new}], new, new)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'new' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: new}], new, new)
listener: handleIdentifier(new, topLevelVariableDeclaration)
parseFieldInitializerOpt(new, new, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -1105,7 +1105,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(null, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'null'., null, {token: null}], null, null)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'null' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: null}], null, null)
listener: handleIdentifier(null, topLevelVariableDeclaration)
parseFieldInitializerOpt(null, null, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -1301,7 +1301,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(rethrow, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
listener: handleIdentifier(rethrow, topLevelVariableDeclaration)
parseFieldInitializerOpt(rethrow, rethrow, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -1329,7 +1329,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(return, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'return'., null, {token: return}], return, return)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'return' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: return}], return, return)
listener: handleIdentifier(return, topLevelVariableDeclaration)
parseFieldInitializerOpt(return, return, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -1453,7 +1453,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(super, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'super'., null, {token: super}], super, super)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'super' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: super}], super, super)
listener: handleIdentifier(super, topLevelVariableDeclaration)
parseFieldInitializerOpt(super, super, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -1481,7 +1481,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(switch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'switch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: switch}], switch, switch)
listener: handleIdentifier(switch, topLevelVariableDeclaration)
parseFieldInitializerOpt(switch, switch, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -1531,7 +1531,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
reportRecoverableErrorWithToken(this, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'this' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: this}], this, this)
listener: handleIdentifier(this, topLevelVariableDeclaration)
parseFieldInitializerOpt(this, this, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -1559,7 +1559,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(throw, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'throw'., null, {token: throw}], throw, throw)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'throw' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: throw}], throw, throw)
listener: handleIdentifier(throw, topLevelVariableDeclaration)
parseFieldInitializerOpt(throw, throw, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -1587,7 +1587,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(true, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'true'., null, {token: true}], true, true)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'true' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: true}], true, true)
listener: handleIdentifier(true, topLevelVariableDeclaration)
parseFieldInitializerOpt(true, true, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -1615,7 +1615,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(try, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'try' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: try}], try, try)
listener: handleIdentifier(try, topLevelVariableDeclaration)
parseFieldInitializerOpt(try, try, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -1667,7 +1667,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(var, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'var' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: var}], var, var)
listener: handleIdentifier(var, topLevelVariableDeclaration)
parseFieldInitializerOpt(var, var, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -1695,7 +1695,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(void, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'void' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: void}], void, void)
listener: handleIdentifier(void, topLevelVariableDeclaration)
parseFieldInitializerOpt(void, void, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -1723,7 +1723,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(while, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'while' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: while}], while, while)
listener: handleIdentifier(while, topLevelVariableDeclaration)
parseFieldInitializerOpt(while, while, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
@@ -1751,7 +1751,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
listener: handleIdentifier(with, topLevelVariableDeclaration)
parseFieldInitializerOpt(with, with, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.expect
index df30d32..ab9b7d5 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.expect
@@ -1,6 +1,6 @@
Problems reported:
-parser/error_recovery/keyword_named_top_level_methods:11:5: Expected an identifier, but got 'assert'.
+parser/error_recovery/keyword_named_top_level_methods:11:5: 'assert' can't be used as an identifier because it's a keyword.
int assert(int x) {
^^^^^^
@@ -8,7 +8,7 @@
return assert(x-1) + 1;
^^^^^^
-parser/error_recovery/keyword_named_top_level_methods:26:5: Expected an identifier, but got 'break'.
+parser/error_recovery/keyword_named_top_level_methods:26:5: 'break' can't be used as an identifier because it's a keyword.
int break(int x) {
^^^^^
@@ -28,31 +28,31 @@
return break(x-1) + 1;
^^^^^
-parser/error_recovery/keyword_named_top_level_methods:31:5: Expected an identifier, but got 'case'.
+parser/error_recovery/keyword_named_top_level_methods:31:5: 'case' can't be used as an identifier because it's a keyword.
int case(int x) {
^^^^
-parser/error_recovery/keyword_named_top_level_methods:33:10: Expected an identifier, but got 'case'.
+parser/error_recovery/keyword_named_top_level_methods:33:10: 'case' can't be used as an identifier because it's a keyword.
return case(x-1) + 1;
^^^^
-parser/error_recovery/keyword_named_top_level_methods:36:5: Expected an identifier, but got 'catch'.
+parser/error_recovery/keyword_named_top_level_methods:36:5: 'catch' can't be used as an identifier because it's a keyword.
int catch(int x) {
^^^^^
-parser/error_recovery/keyword_named_top_level_methods:38:10: Expected an identifier, but got 'catch'.
+parser/error_recovery/keyword_named_top_level_methods:38:10: 'catch' can't be used as an identifier because it's a keyword.
return catch(x-1) + 1;
^^^^^
-parser/error_recovery/keyword_named_top_level_methods:41:5: Expected an identifier, but got 'class'.
+parser/error_recovery/keyword_named_top_level_methods:41:5: 'class' can't be used as an identifier because it's a keyword.
int class(int x) {
^^^^^
-parser/error_recovery/keyword_named_top_level_methods:43:10: Expected an identifier, but got 'class'.
+parser/error_recovery/keyword_named_top_level_methods:43:10: 'class' can't be used as an identifier because it's a keyword.
return class(x-1) + 1;
^^^^^
-parser/error_recovery/keyword_named_top_level_methods:46:5: Expected an identifier, but got 'const'.
+parser/error_recovery/keyword_named_top_level_methods:46:5: 'const' can't be used as an identifier because it's a keyword.
int const(int x) {
^^^^^
@@ -60,7 +60,7 @@
return const(x-1) + 1;
^
-parser/error_recovery/keyword_named_top_level_methods:51:5: Expected an identifier, but got 'continue'.
+parser/error_recovery/keyword_named_top_level_methods:51:5: 'continue' can't be used as an identifier because it's a keyword.
int continue(int x) {
^^^^^^^^
@@ -80,15 +80,15 @@
return continue(x-1) + 1;
^^^^^^^^
-parser/error_recovery/keyword_named_top_level_methods:61:5: Expected an identifier, but got 'default'.
+parser/error_recovery/keyword_named_top_level_methods:61:5: 'default' can't be used as an identifier because it's a keyword.
int default(int x) {
^^^^^^^
-parser/error_recovery/keyword_named_top_level_methods:63:10: Expected an identifier, but got 'default'.
+parser/error_recovery/keyword_named_top_level_methods:63:10: 'default' can't be used as an identifier because it's a keyword.
return default(x-1) + 1;
^^^^^^^
-parser/error_recovery/keyword_named_top_level_methods:71:5: Expected an identifier, but got 'do'.
+parser/error_recovery/keyword_named_top_level_methods:71:5: 'do' can't be used as an identifier because it's a keyword.
int do(int x) {
^^
@@ -116,7 +116,7 @@
}
^
-parser/error_recovery/keyword_named_top_level_methods:81:5: Expected an identifier, but got 'else'.
+parser/error_recovery/keyword_named_top_level_methods:81:5: 'else' can't be used as an identifier because it's a keyword.
int else(int x) {
^^^^
@@ -140,27 +140,27 @@
return else(x-1) + 1;
^^^^
-parser/error_recovery/keyword_named_top_level_methods:86:5: Expected an identifier, but got 'enum'.
+parser/error_recovery/keyword_named_top_level_methods:86:5: 'enum' can't be used as an identifier because it's a keyword.
int enum(int x) {
^^^^
-parser/error_recovery/keyword_named_top_level_methods:88:10: Expected an identifier, but got 'enum'.
+parser/error_recovery/keyword_named_top_level_methods:88:10: 'enum' can't be used as an identifier because it's a keyword.
return enum(x-1) + 1;
^^^^
-parser/error_recovery/keyword_named_top_level_methods:96:5: Expected an identifier, but got 'extends'.
+parser/error_recovery/keyword_named_top_level_methods:96:5: 'extends' can't be used as an identifier because it's a keyword.
int extends(int x) {
^^^^^^^
-parser/error_recovery/keyword_named_top_level_methods:98:10: Expected an identifier, but got 'extends'.
+parser/error_recovery/keyword_named_top_level_methods:98:10: 'extends' can't be used as an identifier because it's a keyword.
return extends(x-1) + 1;
^^^^^^^
-parser/error_recovery/keyword_named_top_level_methods:116:5: Expected an identifier, but got 'false'.
+parser/error_recovery/keyword_named_top_level_methods:116:5: 'false' can't be used as an identifier because it's a keyword.
int false(int x) {
^^^^^
-parser/error_recovery/keyword_named_top_level_methods:121:5: Expected an identifier, but got 'final'.
+parser/error_recovery/keyword_named_top_level_methods:121:5: 'final' can't be used as an identifier because it's a keyword.
int final(int x) {
^^^^^
@@ -200,15 +200,15 @@
return final(x-1) + 1;
^
-parser/error_recovery/keyword_named_top_level_methods:126:5: Expected an identifier, but got 'finally'.
+parser/error_recovery/keyword_named_top_level_methods:126:5: 'finally' can't be used as an identifier because it's a keyword.
int finally(int x) {
^^^^^^^
-parser/error_recovery/keyword_named_top_level_methods:128:10: Expected an identifier, but got 'finally'.
+parser/error_recovery/keyword_named_top_level_methods:128:10: 'finally' can't be used as an identifier because it's a keyword.
return finally(x-1) + 1;
^^^^^^^
-parser/error_recovery/keyword_named_top_level_methods:131:5: Expected an identifier, but got 'for'.
+parser/error_recovery/keyword_named_top_level_methods:131:5: 'for' can't be used as an identifier because it's a keyword.
int for(int x) {
^^^
@@ -236,7 +236,7 @@
return for(x-1) + 1;
^
-parser/error_recovery/keyword_named_top_level_methods:151:5: Expected an identifier, but got 'if'.
+parser/error_recovery/keyword_named_top_level_methods:151:5: 'if' can't be used as an identifier because it's a keyword.
int if(int x) {
^^
@@ -252,15 +252,15 @@
return if(x-1) + 1;
^
-parser/error_recovery/keyword_named_top_level_methods:166:5: Expected an identifier, but got 'in'.
+parser/error_recovery/keyword_named_top_level_methods:166:5: 'in' can't be used as an identifier because it's a keyword.
int in(int x) {
^^
-parser/error_recovery/keyword_named_top_level_methods:168:10: Expected an identifier, but got 'in'.
+parser/error_recovery/keyword_named_top_level_methods:168:10: 'in' can't be used as an identifier because it's a keyword.
return in(x-1) + 1;
^^
-parser/error_recovery/keyword_named_top_level_methods:181:5: Expected an identifier, but got 'is'.
+parser/error_recovery/keyword_named_top_level_methods:181:5: 'is' can't be used as an identifier because it's a keyword.
int is(int x) {
^^
@@ -276,7 +276,7 @@
return is(x-1) + 1;
^
-parser/error_recovery/keyword_named_top_level_methods:206:5: Expected an identifier, but got 'new'.
+parser/error_recovery/keyword_named_top_level_methods:206:5: 'new' can't be used as an identifier because it's a keyword.
int new(int x) {
^^^
@@ -284,19 +284,19 @@
return new(x-1) + 1;
^
-parser/error_recovery/keyword_named_top_level_methods:211:5: Expected an identifier, but got 'null'.
+parser/error_recovery/keyword_named_top_level_methods:211:5: 'null' can't be used as an identifier because it's a keyword.
int null(int x) {
^^^^
-parser/error_recovery/keyword_named_top_level_methods:251:5: Expected an identifier, but got 'rethrow'.
+parser/error_recovery/keyword_named_top_level_methods:251:5: 'rethrow' can't be used as an identifier because it's a keyword.
int rethrow(int x) {
^^^^^^^
-parser/error_recovery/keyword_named_top_level_methods:253:10: Expected an identifier, but got 'rethrow'.
+parser/error_recovery/keyword_named_top_level_methods:253:10: 'rethrow' can't be used as an identifier because it's a keyword.
return rethrow(x-1) + 1;
^^^^^^^
-parser/error_recovery/keyword_named_top_level_methods:256:5: Expected an identifier, but got 'return'.
+parser/error_recovery/keyword_named_top_level_methods:256:5: 'return' can't be used as an identifier because it's a keyword.
int return(int x) {
^^^^^^
@@ -304,11 +304,11 @@
return return(x-1) + 1;
^^^^^^
-parser/error_recovery/keyword_named_top_level_methods:281:5: Expected an identifier, but got 'super'.
+parser/error_recovery/keyword_named_top_level_methods:281:5: 'super' can't be used as an identifier because it's a keyword.
int super(int x) {
^^^^^
-parser/error_recovery/keyword_named_top_level_methods:286:5: Expected an identifier, but got 'switch'.
+parser/error_recovery/keyword_named_top_level_methods:286:5: 'switch' can't be used as an identifier because it's a keyword.
int switch(int x) {
^^^^^^
@@ -328,19 +328,19 @@
return switch(x-1) + 1;
^
-parser/error_recovery/keyword_named_top_level_methods:296:5: Expected an identifier, but got 'this'.
+parser/error_recovery/keyword_named_top_level_methods:296:5: 'this' can't be used as an identifier because it's a keyword.
int this(int x) {
^^^^
-parser/error_recovery/keyword_named_top_level_methods:301:5: Expected an identifier, but got 'throw'.
+parser/error_recovery/keyword_named_top_level_methods:301:5: 'throw' can't be used as an identifier because it's a keyword.
int throw(int x) {
^^^^^
-parser/error_recovery/keyword_named_top_level_methods:306:5: Expected an identifier, but got 'true'.
+parser/error_recovery/keyword_named_top_level_methods:306:5: 'true' can't be used as an identifier because it's a keyword.
int true(int x) {
^^^^
-parser/error_recovery/keyword_named_top_level_methods:311:5: Expected an identifier, but got 'try'.
+parser/error_recovery/keyword_named_top_level_methods:311:5: 'try' can't be used as an identifier because it's a keyword.
int try(int x) {
^^^
@@ -360,7 +360,7 @@
return try(x-1) + 1;
^^^
-parser/error_recovery/keyword_named_top_level_methods:321:5: Expected an identifier, but got 'var'.
+parser/error_recovery/keyword_named_top_level_methods:321:5: 'var' can't be used as an identifier because it's a keyword.
int var(int x) {
^^^
@@ -400,7 +400,7 @@
return var(x-1) + 1;
^
-parser/error_recovery/keyword_named_top_level_methods:326:5: Expected an identifier, but got 'void'.
+parser/error_recovery/keyword_named_top_level_methods:326:5: 'void' can't be used as an identifier because it's a keyword.
int void(int x) {
^^^^
@@ -440,7 +440,7 @@
return void(x-1) + 1;
^
-parser/error_recovery/keyword_named_top_level_methods:331:5: Expected an identifier, but got 'while'.
+parser/error_recovery/keyword_named_top_level_methods:331:5: 'while' can't be used as an identifier because it's a keyword.
int while(int x) {
^^^^^
@@ -456,11 +456,11 @@
return while(x-1) + 1;
^
-parser/error_recovery/keyword_named_top_level_methods:336:5: Expected an identifier, but got 'with'.
+parser/error_recovery/keyword_named_top_level_methods:336:5: 'with' can't be used as an identifier because it's a keyword.
int with(int x) {
^^^^
-parser/error_recovery/keyword_named_top_level_methods:338:10: Expected an identifier, but got 'with'.
+parser/error_recovery/keyword_named_top_level_methods:338:10: 'with' can't be used as an identifier because it's a keyword.
return with(x-1) + 1;
^^^^
@@ -586,7 +586,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(assert)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'assert'., null, {token: assert}], assert, assert)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'assert' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: assert}], assert, assert)
handleIdentifier(assert, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -756,7 +756,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(break)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'break' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: break}], break, break)
handleIdentifier(break, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -788,7 +788,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., Try inserting an identifier before 'break'., {token: break}], break, break)
handleIdentifier(, expression)
handleNoTypeArguments(break)
handleNoArguments(break)
@@ -820,7 +820,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(case)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
handleIdentifier(case, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -852,7 +852,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
handleIdentifier(case, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -879,7 +879,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(catch)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
handleIdentifier(catch, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -911,7 +911,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
handleIdentifier(catch, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -938,7 +938,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(class)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
handleIdentifier(class, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -970,7 +970,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
handleIdentifier(class, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -997,7 +997,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(const)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'const'., null, {token: const}], const, const)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'const' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: const}], const, const)
handleIdentifier(const, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -1030,7 +1030,7 @@
endIfStatement(if, null)
beginReturnStatement(return)
beginConstExpression(const)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
handleIdentifier(, constructorReference)
beginConstructorReference()
handleNoTypeArguments(()
@@ -1060,7 +1060,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(continue)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'continue' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: continue}], continue, continue)
handleIdentifier(continue, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -1092,7 +1092,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., Try inserting an identifier before 'continue'., {token: continue}], continue, continue)
handleIdentifier(, expression)
handleNoTypeArguments(continue)
handleNoArguments(continue)
@@ -1181,7 +1181,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(default)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
handleIdentifier(default, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -1213,7 +1213,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
handleIdentifier(default, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -1297,7 +1297,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(do)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'do' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: do}], do, do)
handleIdentifier(do, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -1329,7 +1329,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., Try inserting an identifier before 'do'., {token: do}], do, do)
handleIdentifier(, expression)
handleNoTypeArguments(do)
handleNoArguments(do)
@@ -1353,7 +1353,7 @@
endDoWhileStatementBody(;)
handleRecoverableError(Message[ExpectedButGot, Expected 'while' before this., null, {string: while}], }, })
handleRecoverableError(Message[ExpectedToken, Expected to find '('., null, {string: (}], }, })
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '}'., null, {token: }}], }, })
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '}'., Try inserting an identifier before '}'., {token: }}], }, })
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
@@ -1428,7 +1428,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(else)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'else' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: else}], else, else)
handleIdentifier(else, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -1460,14 +1460,14 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., Try inserting an identifier before 'else'., {token: else}], else, else)
handleIdentifier(, expression)
handleNoTypeArguments(else)
handleNoArguments(else)
handleSend(, else)
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], else, else)
endReturnStatement(true, return, ;)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., Try inserting an identifier before 'else'., {token: else}], else, else)
handleIdentifier(, expression)
handleNoTypeArguments(else)
handleNoArguments(else)
@@ -1497,7 +1497,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(enum)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
handleIdentifier(enum, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -1529,7 +1529,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
handleIdentifier(enum, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -1613,7 +1613,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(extends)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
handleIdentifier(extends, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -1645,7 +1645,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
handleIdentifier(extends, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -1843,7 +1843,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(false)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'false'., null, {token: false}], false, false)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'false' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: false}], false, false)
handleIdentifier(false, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -1901,7 +1901,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(final)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'final' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: final}], final, final)
handleIdentifier(final, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -1933,7 +1933,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., Try inserting an identifier before 'final'., {token: final}], final, final)
handleIdentifier(, expression)
handleNoTypeArguments(final)
handleNoArguments(final)
@@ -1944,7 +1944,7 @@
endMetadataStar(0)
handleNoType(final)
beginVariablesDeclaration((, null, final)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
handleIdentifier(, localVariableDeclaration)
beginInitializedIdentifier()
handleNoVariableInitializer()
@@ -1960,7 +1960,7 @@
endBinaryExpression(-)
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], 1, 1)
handleExpressionStatement(;)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
@@ -1987,7 +1987,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(finally)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
handleIdentifier(finally, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -2019,7 +2019,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
handleIdentifier(finally, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -2046,7 +2046,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(for)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'for' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: for}], for, for)
handleIdentifier(for, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -2078,7 +2078,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., Try inserting an identifier before 'for'., {token: for}], for, for)
handleIdentifier(, expression)
handleNoTypeArguments(for)
handleNoArguments(for)
@@ -2095,7 +2095,7 @@
endBinaryExpression(-)
handleForInitializerExpressionStatement(1, false)
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], 1, 1)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
@@ -2296,7 +2296,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(if)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'if' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: if}], if, if)
handleIdentifier(if, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -2328,7 +2328,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., Try inserting an identifier before 'if'., {token: if}], if, if)
handleIdentifier(, expression)
handleNoTypeArguments(if)
handleNoArguments(if)
@@ -2480,7 +2480,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(in)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
handleIdentifier(in, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -2512,7 +2512,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
handleIdentifier(in, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -2653,7 +2653,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(is)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'is' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: is}], is, is)
handleIdentifier(is, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -2685,7 +2685,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., Try inserting an identifier before 'is'., {token: is}], is, is)
handleIdentifier(, expression)
handleNoTypeArguments(is)
handleNoArguments(is)
@@ -2949,7 +2949,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(new)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'new'., null, {token: new}], new, new)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'new' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: new}], new, new)
handleIdentifier(new, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -2982,7 +2982,7 @@
endIfStatement(if, null)
beginReturnStatement(return)
beginNewExpression(new)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
handleIdentifier(, constructorReference)
beginConstructorReference()
handleNoTypeArguments(()
@@ -3012,7 +3012,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(null)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'null'., null, {token: null}], null, null)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'null' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: null}], null, null)
handleIdentifier(null, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -3469,7 +3469,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(rethrow)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
handleIdentifier(rethrow, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -3501,7 +3501,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
handleIdentifier(rethrow, expression)
handleNoTypeArguments(()
beginArguments(()
@@ -3528,7 +3528,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(return)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'return'., null, {token: return}], return, return)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'return' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: return}], return, return)
handleIdentifier(return, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -3811,7 +3811,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(super)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'super'., null, {token: super}], super, super)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'super' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: super}], super, super)
handleIdentifier(super, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -3869,7 +3869,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(switch)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'switch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: switch}], switch, switch)
handleIdentifier(switch, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -3901,7 +3901,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., Try inserting an identifier before 'switch'., {token: switch}], switch, switch)
handleIdentifier(, expression)
handleNoTypeArguments(switch)
handleNoArguments(switch)
@@ -3997,7 +3997,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(this)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'this' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: this}], this, this)
handleIdentifier(this, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -4055,7 +4055,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(throw)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'throw'., null, {token: throw}], throw, throw)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'throw' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: throw}], throw, throw)
handleIdentifier(throw, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -4110,7 +4110,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(true)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'true'., null, {token: true}], true, true)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'true' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: true}], true, true)
handleIdentifier(true, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -4168,7 +4168,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(try)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'try' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: try}], try, try)
handleIdentifier(try, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -4200,7 +4200,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., Try inserting an identifier before 'try'., {token: try}], try, try)
handleIdentifier(, expression)
handleNoTypeArguments(try)
handleNoArguments(try)
@@ -4292,7 +4292,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(var)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'var' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: var}], var, var)
handleIdentifier(var, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -4324,7 +4324,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., Try inserting an identifier before 'var'., {token: var}], var, var)
handleIdentifier(, expression)
handleNoTypeArguments(var)
handleNoArguments(var)
@@ -4335,7 +4335,7 @@
endMetadataStar(0)
handleNoType(var)
beginVariablesDeclaration((, null, var)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
handleIdentifier(, localVariableDeclaration)
beginInitializedIdentifier()
handleNoVariableInitializer()
@@ -4351,7 +4351,7 @@
endBinaryExpression(-)
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], 1, 1)
handleExpressionStatement(;)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
@@ -4378,7 +4378,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(void)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'void' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: void}], void, void)
handleIdentifier(void, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -4410,7 +4410,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., Try inserting an identifier before 'void'., {token: void}], void, void)
handleIdentifier(, expression)
handleNoTypeArguments(void)
handleNoArguments(void)
@@ -4421,7 +4421,7 @@
endMetadataStar(0)
handleVoidKeyword(void)
beginVariablesDeclaration((, null, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
handleIdentifier(, localVariableDeclaration)
beginInitializedIdentifier()
handleNoVariableInitializer()
@@ -4437,7 +4437,7 @@
endBinaryExpression(-)
handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], 1, 1)
handleExpressionStatement(;)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
handleIdentifier(, expression)
handleNoTypeArguments())
handleNoArguments())
@@ -4464,7 +4464,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(while)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'while' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: while}], while, while)
handleIdentifier(while, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -4496,7 +4496,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., Try inserting an identifier before 'while'., {token: while}], while, while)
handleIdentifier(, expression)
handleNoTypeArguments(while)
handleNoArguments(while)
@@ -4534,7 +4534,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(with)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
handleIdentifier(with, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -4566,7 +4566,7 @@
endThenStatement(;)
endIfStatement(if, null)
beginReturnStatement(return)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
handleIdentifier(with, expression)
handleNoTypeArguments(()
beginArguments(()
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.intertwined.expect
index f6e0e65..1ce425d 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.intertwined.expect
@@ -291,7 +291,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(assert, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'assert'., null, {token: assert}], assert, assert)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'assert' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: assert}], assert, assert)
listener: handleIdentifier(assert, topLevelFunctionDeclaration)
parseMethodTypeVar(assert)
listener: handleNoTypeVariables(()
@@ -701,7 +701,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(break, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'break' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: break}], break, break)
listener: handleIdentifier(break, topLevelFunctionDeclaration)
parseMethodTypeVar(break)
listener: handleNoTypeVariables(()
@@ -784,7 +784,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(break, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., Try inserting an identifier before 'break'., {token: break}], break, break)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(break)
@@ -873,7 +873,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(case, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
listener: handleIdentifier(case, topLevelFunctionDeclaration)
parseMethodTypeVar(case)
listener: handleNoTypeVariables(()
@@ -956,7 +956,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(case, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
listener: handleIdentifier(case, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(case)
@@ -1013,7 +1013,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(catch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
listener: handleIdentifier(catch, topLevelFunctionDeclaration)
parseMethodTypeVar(catch)
listener: handleNoTypeVariables(()
@@ -1096,7 +1096,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(catch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
listener: handleIdentifier(catch, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(catch)
@@ -1153,7 +1153,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(class, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
listener: handleIdentifier(class, topLevelFunctionDeclaration)
parseMethodTypeVar(class)
listener: handleNoTypeVariables(()
@@ -1236,7 +1236,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(class, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
listener: handleIdentifier(class, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(class)
@@ -1293,7 +1293,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(const, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'const'., null, {token: const}], const, const)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'const' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: const}], const, const)
listener: handleIdentifier(const, topLevelFunctionDeclaration)
parseMethodTypeVar(const)
listener: handleNoTypeVariables(()
@@ -1376,9 +1376,9 @@
listener: beginConstExpression(const)
parseConstructorReference(const, null)
ensureIdentifier(const, constructorReference)
- insertSyntheticIdentifier(const, constructorReference, message: Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], messageOnToken: null)
- reportRecoverableError((, Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}])
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ insertSyntheticIdentifier(const, constructorReference, message: Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], messageOnToken: null)
+ reportRecoverableError((, Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}])
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
rewriter()
listener: handleIdentifier(, constructorReference)
listener: beginConstructorReference()
@@ -1439,7 +1439,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(continue, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'continue' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: continue}], continue, continue)
listener: handleIdentifier(continue, topLevelFunctionDeclaration)
parseMethodTypeVar(continue)
listener: handleNoTypeVariables(()
@@ -1522,7 +1522,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(continue, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., Try inserting an identifier before 'continue'., {token: continue}], continue, continue)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(continue)
@@ -1748,7 +1748,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(default, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
listener: handleIdentifier(default, topLevelFunctionDeclaration)
parseMethodTypeVar(default)
listener: handleNoTypeVariables(()
@@ -1831,7 +1831,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(default, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
listener: handleIdentifier(default, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(default)
@@ -2025,7 +2025,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(do, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'do' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: do}], do, do)
listener: handleIdentifier(do, topLevelFunctionDeclaration)
parseMethodTypeVar(do)
listener: handleNoTypeVariables(()
@@ -2108,7 +2108,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(do, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., Try inserting an identifier before 'do'., {token: do}], do, do)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(do)
@@ -2187,7 +2187,7 @@
parseSend((, expression)
ensureIdentifier((, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '}'., null, {token: }}], }, })
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '}'., Try inserting an identifier before '}'., {token: }}], }, })
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
@@ -2357,7 +2357,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(else, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'else' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: else}], else, else)
listener: handleIdentifier(else, topLevelFunctionDeclaration)
parseMethodTypeVar(else)
listener: handleNoTypeVariables(()
@@ -2440,7 +2440,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(else, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., Try inserting an identifier before 'else'., {token: else}], else, else)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(else)
@@ -2468,7 +2468,7 @@
parseSend(;, expression)
ensureIdentifier(;, expression)
reportRecoverableErrorWithToken(else, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., Try inserting an identifier before 'else'., {token: else}], else, else)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(else)
@@ -2546,7 +2546,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(enum, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
listener: handleIdentifier(enum, topLevelFunctionDeclaration)
parseMethodTypeVar(enum)
listener: handleNoTypeVariables(()
@@ -2629,7 +2629,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(enum, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
listener: handleIdentifier(enum, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(enum)
@@ -2823,7 +2823,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(extends, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
listener: handleIdentifier(extends, topLevelFunctionDeclaration)
parseMethodTypeVar(extends)
listener: handleNoTypeVariables(()
@@ -2906,7 +2906,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(extends, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
listener: handleIdentifier(extends, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(extends)
@@ -3374,7 +3374,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(false, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'false'., null, {token: false}], false, false)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'false' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: false}], false, false)
listener: handleIdentifier(false, topLevelFunctionDeclaration)
parseMethodTypeVar(false)
listener: handleNoTypeVariables(()
@@ -3510,7 +3510,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(final, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'final' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: final}], final, final)
listener: handleIdentifier(final, topLevelFunctionDeclaration)
parseMethodTypeVar(final)
listener: handleNoTypeVariables(()
@@ -3593,7 +3593,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(final, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., Try inserting an identifier before 'final'., {token: final}], final, final)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(final)
@@ -3619,7 +3619,7 @@
parseOptionallyInitializedIdentifier(final)
ensureIdentifier(final, localVariableDeclaration)
reportRecoverableErrorWithToken((, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
rewriter()
listener: handleIdentifier(, localVariableDeclaration)
listener: beginInitializedIdentifier()
@@ -3675,7 +3675,7 @@
parseSend(;, expression)
ensureIdentifier(;, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
@@ -3740,7 +3740,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(finally, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
listener: handleIdentifier(finally, topLevelFunctionDeclaration)
parseMethodTypeVar(finally)
listener: handleNoTypeVariables(()
@@ -3823,7 +3823,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(finally, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
listener: handleIdentifier(finally, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(finally)
@@ -3880,7 +3880,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(for, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'for' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: for}], for, for)
listener: handleIdentifier(for, topLevelFunctionDeclaration)
parseMethodTypeVar(for)
listener: handleNoTypeVariables(()
@@ -3963,7 +3963,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(for, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., Try inserting an identifier before 'for'., {token: for}], for, for)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(for)
@@ -4019,7 +4019,7 @@
parseSend(;, expression)
ensureIdentifier(;, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
@@ -4496,7 +4496,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(if, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'if' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: if}], if, if)
listener: handleIdentifier(if, topLevelFunctionDeclaration)
parseMethodTypeVar(if)
listener: handleNoTypeVariables(()
@@ -4579,7 +4579,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(if, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., Try inserting an identifier before 'if'., {token: if}], if, if)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(if)
@@ -4947,7 +4947,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(in, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
listener: handleIdentifier(in, topLevelFunctionDeclaration)
parseMethodTypeVar(in)
listener: handleNoTypeVariables(()
@@ -5030,7 +5030,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(in, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
listener: handleIdentifier(in, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(in)
@@ -5361,7 +5361,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(is, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'is' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: is}], is, is)
listener: handleIdentifier(is, topLevelFunctionDeclaration)
parseMethodTypeVar(is)
listener: handleNoTypeVariables(()
@@ -5444,7 +5444,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(is, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., Try inserting an identifier before 'is'., {token: is}], is, is)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(is)
@@ -6081,7 +6081,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(new, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'new'., null, {token: new}], new, new)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'new' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: new}], new, new)
listener: handleIdentifier(new, topLevelFunctionDeclaration)
parseMethodTypeVar(new)
listener: handleNoTypeVariables(()
@@ -6164,9 +6164,9 @@
listener: beginNewExpression(new)
parseConstructorReference(new, null)
ensureIdentifier(new, constructorReference)
- insertSyntheticIdentifier(new, constructorReference, message: Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], messageOnToken: null)
- reportRecoverableError((, Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}])
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ insertSyntheticIdentifier(new, constructorReference, message: Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], messageOnToken: null)
+ reportRecoverableError((, Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}])
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
rewriter()
listener: handleIdentifier(, constructorReference)
listener: beginConstructorReference()
@@ -6227,7 +6227,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(null, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'null'., null, {token: null}], null, null)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'null' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: null}], null, null)
listener: handleIdentifier(null, topLevelFunctionDeclaration)
parseMethodTypeVar(null)
listener: handleNoTypeVariables(()
@@ -7322,7 +7322,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(rethrow, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
listener: handleIdentifier(rethrow, topLevelFunctionDeclaration)
parseMethodTypeVar(rethrow)
listener: handleNoTypeVariables(()
@@ -7405,7 +7405,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(rethrow, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
listener: handleIdentifier(rethrow, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(rethrow)
@@ -7462,7 +7462,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(return, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'return'., null, {token: return}], return, return)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'return' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: return}], return, return)
listener: handleIdentifier(return, topLevelFunctionDeclaration)
parseMethodTypeVar(return)
listener: handleNoTypeVariables(()
@@ -8147,7 +8147,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(super, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'super'., null, {token: super}], super, super)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'super' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: super}], super, super)
listener: handleIdentifier(super, topLevelFunctionDeclaration)
parseMethodTypeVar(super)
listener: handleNoTypeVariables(()
@@ -8282,7 +8282,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(switch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'switch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: switch}], switch, switch)
listener: handleIdentifier(switch, topLevelFunctionDeclaration)
parseMethodTypeVar(switch)
listener: handleNoTypeVariables(()
@@ -8365,7 +8365,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(switch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., Try inserting an identifier before 'switch'., {token: switch}], switch, switch)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(switch)
@@ -8603,7 +8603,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, false)
reportRecoverableErrorWithToken(this, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'this' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: this}], this, this)
listener: handleIdentifier(this, topLevelFunctionDeclaration)
parseMethodTypeVar(this)
listener: handleNoTypeVariables(()
@@ -8738,7 +8738,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(throw, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'throw'., null, {token: throw}], throw, throw)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'throw' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: throw}], throw, throw)
listener: handleIdentifier(throw, topLevelFunctionDeclaration)
parseMethodTypeVar(throw)
listener: handleNoTypeVariables(()
@@ -8874,7 +8874,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(true, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'true'., null, {token: true}], true, true)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'true' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: true}], true, true)
listener: handleIdentifier(true, topLevelFunctionDeclaration)
parseMethodTypeVar(true)
listener: handleNoTypeVariables(()
@@ -9010,7 +9010,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(try, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'try' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: try}], try, try)
listener: handleIdentifier(try, topLevelFunctionDeclaration)
parseMethodTypeVar(try)
listener: handleNoTypeVariables(()
@@ -9093,7 +9093,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(try, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., Try inserting an identifier before 'try'., {token: try}], try, try)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(try)
@@ -9325,7 +9325,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(var, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'var' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: var}], var, var)
listener: handleIdentifier(var, topLevelFunctionDeclaration)
parseMethodTypeVar(var)
listener: handleNoTypeVariables(()
@@ -9408,7 +9408,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(var, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., Try inserting an identifier before 'var'., {token: var}], var, var)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(var)
@@ -9434,7 +9434,7 @@
parseOptionallyInitializedIdentifier(var)
ensureIdentifier(var, localVariableDeclaration)
reportRecoverableErrorWithToken((, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
rewriter()
listener: handleIdentifier(, localVariableDeclaration)
listener: beginInitializedIdentifier()
@@ -9490,7 +9490,7 @@
parseSend(;, expression)
ensureIdentifier(;, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
@@ -9555,7 +9555,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(void, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'void' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: void}], void, void)
listener: handleIdentifier(void, topLevelFunctionDeclaration)
parseMethodTypeVar(void)
listener: handleNoTypeVariables(()
@@ -9638,7 +9638,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(void, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., Try inserting an identifier before 'void'., {token: void}], void, void)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(void)
@@ -9665,7 +9665,7 @@
parseOptionallyInitializedIdentifier(void)
ensureIdentifier(void, localVariableDeclaration)
reportRecoverableErrorWithToken((, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., Try inserting an identifier before '('., {token: (}], (, ()
rewriter()
listener: handleIdentifier(, localVariableDeclaration)
listener: beginInitializedIdentifier()
@@ -9721,7 +9721,7 @@
parseSend(;, expression)
ensureIdentifier(;, expression)
reportRecoverableErrorWithToken(), Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., null, {token: )}], ), ))
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ')'., Try inserting an identifier before ')'., {token: )}], ), ))
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments())
@@ -9786,7 +9786,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(while, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'while' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: while}], while, while)
listener: handleIdentifier(while, topLevelFunctionDeclaration)
parseMethodTypeVar(while)
listener: handleNoTypeVariables(()
@@ -9869,7 +9869,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(while, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., Try inserting an identifier before 'while'., {token: while}], while, while)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(while)
@@ -9963,7 +9963,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
listener: handleIdentifier(with, topLevelFunctionDeclaration)
parseMethodTypeVar(with)
listener: handleNoTypeVariables(()
@@ -10046,7 +10046,7 @@
parseSend(return, expression)
ensureIdentifier(return, expression)
reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
listener: handleIdentifier(with, expression)
listener: handleNoTypeArguments(()
parseArgumentsOpt(with)
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_typedefs.dart.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_typedefs.dart.expect
index 22a636f..f7f2800 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_typedefs.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_typedefs.dart.expect
@@ -1,430 +1,430 @@
Problems reported:
-parser/error_recovery/keyword_named_typedefs:1:14: Expected an identifier, but got 'abstract'.
+parser/error_recovery/keyword_named_typedefs:1:14: 'abstract' can't be used as an identifier because it's a keyword.
typedef void abstract();
^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:2:9: Expected an identifier, but got 'abstract'.
+parser/error_recovery/keyword_named_typedefs:2:9: 'abstract' can't be used as an identifier because it's a keyword.
typedef abstract = void Function();
^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:3:14: Expected an identifier, but got 'as'.
+parser/error_recovery/keyword_named_typedefs:3:14: 'as' can't be used as an identifier because it's a keyword.
typedef void as();
^^
-parser/error_recovery/keyword_named_typedefs:4:9: Expected an identifier, but got 'as'.
+parser/error_recovery/keyword_named_typedefs:4:9: 'as' can't be used as an identifier because it's a keyword.
typedef as = void Function();
^^
-parser/error_recovery/keyword_named_typedefs:5:14: Expected an identifier, but got 'assert'.
+parser/error_recovery/keyword_named_typedefs:5:14: 'assert' can't be used as an identifier because it's a keyword.
typedef void assert();
^^^^^^
-parser/error_recovery/keyword_named_typedefs:6:9: Expected an identifier, but got 'assert'.
+parser/error_recovery/keyword_named_typedefs:6:9: 'assert' can't be used as an identifier because it's a keyword.
typedef assert = void Function();
^^^^^^
-parser/error_recovery/keyword_named_typedefs:11:14: Expected an identifier, but got 'break'.
+parser/error_recovery/keyword_named_typedefs:11:14: 'break' can't be used as an identifier because it's a keyword.
typedef void break();
^^^^^
-parser/error_recovery/keyword_named_typedefs:12:9: Expected an identifier, but got 'break'.
+parser/error_recovery/keyword_named_typedefs:12:9: 'break' can't be used as an identifier because it's a keyword.
typedef break = void Function();
^^^^^
-parser/error_recovery/keyword_named_typedefs:13:14: Expected an identifier, but got 'case'.
+parser/error_recovery/keyword_named_typedefs:13:14: 'case' can't be used as an identifier because it's a keyword.
typedef void case();
^^^^
-parser/error_recovery/keyword_named_typedefs:14:9: Expected an identifier, but got 'case'.
+parser/error_recovery/keyword_named_typedefs:14:9: 'case' can't be used as an identifier because it's a keyword.
typedef case = void Function();
^^^^
-parser/error_recovery/keyword_named_typedefs:15:14: Expected an identifier, but got 'catch'.
+parser/error_recovery/keyword_named_typedefs:15:14: 'catch' can't be used as an identifier because it's a keyword.
typedef void catch();
^^^^^
-parser/error_recovery/keyword_named_typedefs:16:9: Expected an identifier, but got 'catch'.
+parser/error_recovery/keyword_named_typedefs:16:9: 'catch' can't be used as an identifier because it's a keyword.
typedef catch = void Function();
^^^^^
-parser/error_recovery/keyword_named_typedefs:17:14: Expected an identifier, but got 'class'.
+parser/error_recovery/keyword_named_typedefs:17:14: 'class' can't be used as an identifier because it's a keyword.
typedef void class();
^^^^^
-parser/error_recovery/keyword_named_typedefs:18:9: Expected an identifier, but got 'class'.
+parser/error_recovery/keyword_named_typedefs:18:9: 'class' can't be used as an identifier because it's a keyword.
typedef class = void Function();
^^^^^
-parser/error_recovery/keyword_named_typedefs:19:14: Expected an identifier, but got 'const'.
+parser/error_recovery/keyword_named_typedefs:19:14: 'const' can't be used as an identifier because it's a keyword.
typedef void const();
^^^^^
-parser/error_recovery/keyword_named_typedefs:20:9: Expected an identifier, but got 'const'.
+parser/error_recovery/keyword_named_typedefs:20:9: 'const' can't be used as an identifier because it's a keyword.
typedef const = void Function();
^^^^^
-parser/error_recovery/keyword_named_typedefs:21:14: Expected an identifier, but got 'continue'.
+parser/error_recovery/keyword_named_typedefs:21:14: 'continue' can't be used as an identifier because it's a keyword.
typedef void continue();
^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:22:9: Expected an identifier, but got 'continue'.
+parser/error_recovery/keyword_named_typedefs:22:9: 'continue' can't be used as an identifier because it's a keyword.
typedef continue = void Function();
^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:23:14: Expected an identifier, but got 'covariant'.
+parser/error_recovery/keyword_named_typedefs:23:14: 'covariant' can't be used as an identifier because it's a keyword.
typedef void covariant();
^^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:24:9: Expected an identifier, but got 'covariant'.
+parser/error_recovery/keyword_named_typedefs:24:9: 'covariant' can't be used as an identifier because it's a keyword.
typedef covariant = void Function();
^^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:25:14: Expected an identifier, but got 'default'.
+parser/error_recovery/keyword_named_typedefs:25:14: 'default' can't be used as an identifier because it's a keyword.
typedef void default();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:26:9: Expected an identifier, but got 'default'.
+parser/error_recovery/keyword_named_typedefs:26:9: 'default' can't be used as an identifier because it's a keyword.
typedef default = void Function();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:27:14: Expected an identifier, but got 'deferred'.
+parser/error_recovery/keyword_named_typedefs:27:14: 'deferred' can't be used as an identifier because it's a keyword.
typedef void deferred();
^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:28:9: Expected an identifier, but got 'deferred'.
+parser/error_recovery/keyword_named_typedefs:28:9: 'deferred' can't be used as an identifier because it's a keyword.
typedef deferred = void Function();
^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:29:14: Expected an identifier, but got 'do'.
+parser/error_recovery/keyword_named_typedefs:29:14: 'do' can't be used as an identifier because it's a keyword.
typedef void do();
^^
-parser/error_recovery/keyword_named_typedefs:30:9: Expected an identifier, but got 'do'.
+parser/error_recovery/keyword_named_typedefs:30:9: 'do' can't be used as an identifier because it's a keyword.
typedef do = void Function();
^^
-parser/error_recovery/keyword_named_typedefs:31:14: Expected an identifier, but got 'dynamic'.
+parser/error_recovery/keyword_named_typedefs:31:14: 'dynamic' can't be used as an identifier because it's a keyword.
typedef void dynamic();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:32:9: Expected an identifier, but got 'dynamic'.
+parser/error_recovery/keyword_named_typedefs:32:9: 'dynamic' can't be used as an identifier because it's a keyword.
typedef dynamic = void Function();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:33:14: Expected an identifier, but got 'else'.
+parser/error_recovery/keyword_named_typedefs:33:14: 'else' can't be used as an identifier because it's a keyword.
typedef void else();
^^^^
-parser/error_recovery/keyword_named_typedefs:34:9: Expected an identifier, but got 'else'.
+parser/error_recovery/keyword_named_typedefs:34:9: 'else' can't be used as an identifier because it's a keyword.
typedef else = void Function();
^^^^
-parser/error_recovery/keyword_named_typedefs:35:14: Expected an identifier, but got 'enum'.
+parser/error_recovery/keyword_named_typedefs:35:14: 'enum' can't be used as an identifier because it's a keyword.
typedef void enum();
^^^^
-parser/error_recovery/keyword_named_typedefs:36:9: Expected an identifier, but got 'enum'.
+parser/error_recovery/keyword_named_typedefs:36:9: 'enum' can't be used as an identifier because it's a keyword.
typedef enum = void Function();
^^^^
-parser/error_recovery/keyword_named_typedefs:37:14: Expected an identifier, but got 'export'.
+parser/error_recovery/keyword_named_typedefs:37:14: 'export' can't be used as an identifier because it's a keyword.
typedef void export();
^^^^^^
-parser/error_recovery/keyword_named_typedefs:38:9: Expected an identifier, but got 'export'.
+parser/error_recovery/keyword_named_typedefs:38:9: 'export' can't be used as an identifier because it's a keyword.
typedef export = void Function();
^^^^^^
-parser/error_recovery/keyword_named_typedefs:39:14: Expected an identifier, but got 'extends'.
+parser/error_recovery/keyword_named_typedefs:39:14: 'extends' can't be used as an identifier because it's a keyword.
typedef void extends();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:40:9: Expected an identifier, but got 'extends'.
+parser/error_recovery/keyword_named_typedefs:40:9: 'extends' can't be used as an identifier because it's a keyword.
typedef extends = void Function();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:41:14: Expected an identifier, but got 'extension'.
+parser/error_recovery/keyword_named_typedefs:41:14: 'extension' can't be used as an identifier because it's a keyword.
typedef void extension();
^^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:42:9: Expected an identifier, but got 'extension'.
+parser/error_recovery/keyword_named_typedefs:42:9: 'extension' can't be used as an identifier because it's a keyword.
typedef extension = void Function();
^^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:43:14: Expected an identifier, but got 'external'.
+parser/error_recovery/keyword_named_typedefs:43:14: 'external' can't be used as an identifier because it's a keyword.
typedef void external();
^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:44:9: Expected an identifier, but got 'external'.
+parser/error_recovery/keyword_named_typedefs:44:9: 'external' can't be used as an identifier because it's a keyword.
typedef external = void Function();
^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:45:14: Expected an identifier, but got 'factory'.
+parser/error_recovery/keyword_named_typedefs:45:14: 'factory' can't be used as an identifier because it's a keyword.
typedef void factory();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:46:9: Expected an identifier, but got 'factory'.
+parser/error_recovery/keyword_named_typedefs:46:9: 'factory' can't be used as an identifier because it's a keyword.
typedef factory = void Function();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:47:14: Expected an identifier, but got 'false'.
+parser/error_recovery/keyword_named_typedefs:47:14: 'false' can't be used as an identifier because it's a keyword.
typedef void false();
^^^^^
-parser/error_recovery/keyword_named_typedefs:48:9: Expected an identifier, but got 'false'.
+parser/error_recovery/keyword_named_typedefs:48:9: 'false' can't be used as an identifier because it's a keyword.
typedef false = void Function();
^^^^^
-parser/error_recovery/keyword_named_typedefs:49:14: Expected an identifier, but got 'final'.
+parser/error_recovery/keyword_named_typedefs:49:14: 'final' can't be used as an identifier because it's a keyword.
typedef void final();
^^^^^
-parser/error_recovery/keyword_named_typedefs:50:9: Expected an identifier, but got 'final'.
+parser/error_recovery/keyword_named_typedefs:50:9: 'final' can't be used as an identifier because it's a keyword.
typedef final = void Function();
^^^^^
-parser/error_recovery/keyword_named_typedefs:51:14: Expected an identifier, but got 'finally'.
+parser/error_recovery/keyword_named_typedefs:51:14: 'finally' can't be used as an identifier because it's a keyword.
typedef void finally();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:52:9: Expected an identifier, but got 'finally'.
+parser/error_recovery/keyword_named_typedefs:52:9: 'finally' can't be used as an identifier because it's a keyword.
typedef finally = void Function();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:53:14: Expected an identifier, but got 'for'.
+parser/error_recovery/keyword_named_typedefs:53:14: 'for' can't be used as an identifier because it's a keyword.
typedef void for();
^^^
-parser/error_recovery/keyword_named_typedefs:54:9: Expected an identifier, but got 'for'.
+parser/error_recovery/keyword_named_typedefs:54:9: 'for' can't be used as an identifier because it's a keyword.
typedef for = void Function();
^^^
-parser/error_recovery/keyword_named_typedefs:55:14: Expected an identifier, but got 'Function'.
+parser/error_recovery/keyword_named_typedefs:55:14: 'Function' can't be used as an identifier because it's a keyword.
typedef void Function();
^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:56:9: Expected an identifier, but got 'Function'.
+parser/error_recovery/keyword_named_typedefs:56:9: 'Function' can't be used as an identifier because it's a keyword.
typedef Function = void Function();
^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:57:14: Expected an identifier, but got 'get'.
+parser/error_recovery/keyword_named_typedefs:57:14: 'get' can't be used as an identifier because it's a keyword.
typedef void get();
^^^
-parser/error_recovery/keyword_named_typedefs:58:9: Expected an identifier, but got 'get'.
+parser/error_recovery/keyword_named_typedefs:58:9: 'get' can't be used as an identifier because it's a keyword.
typedef get = void Function();
^^^
-parser/error_recovery/keyword_named_typedefs:61:14: Expected an identifier, but got 'if'.
+parser/error_recovery/keyword_named_typedefs:61:14: 'if' can't be used as an identifier because it's a keyword.
typedef void if();
^^
-parser/error_recovery/keyword_named_typedefs:62:9: Expected an identifier, but got 'if'.
+parser/error_recovery/keyword_named_typedefs:62:9: 'if' can't be used as an identifier because it's a keyword.
typedef if = void Function();
^^
-parser/error_recovery/keyword_named_typedefs:63:14: Expected an identifier, but got 'implements'.
+parser/error_recovery/keyword_named_typedefs:63:14: 'implements' can't be used as an identifier because it's a keyword.
typedef void implements();
^^^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:64:9: Expected an identifier, but got 'implements'.
+parser/error_recovery/keyword_named_typedefs:64:9: 'implements' can't be used as an identifier because it's a keyword.
typedef implements = void Function();
^^^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:65:14: Expected an identifier, but got 'import'.
+parser/error_recovery/keyword_named_typedefs:65:14: 'import' can't be used as an identifier because it's a keyword.
typedef void import();
^^^^^^
-parser/error_recovery/keyword_named_typedefs:66:9: Expected an identifier, but got 'import'.
+parser/error_recovery/keyword_named_typedefs:66:9: 'import' can't be used as an identifier because it's a keyword.
typedef import = void Function();
^^^^^^
-parser/error_recovery/keyword_named_typedefs:67:14: Expected an identifier, but got 'in'.
+parser/error_recovery/keyword_named_typedefs:67:14: 'in' can't be used as an identifier because it's a keyword.
typedef void in();
^^
-parser/error_recovery/keyword_named_typedefs:68:9: Expected an identifier, but got 'in'.
+parser/error_recovery/keyword_named_typedefs:68:9: 'in' can't be used as an identifier because it's a keyword.
typedef in = void Function();
^^
-parser/error_recovery/keyword_named_typedefs:71:14: Expected an identifier, but got 'interface'.
+parser/error_recovery/keyword_named_typedefs:71:14: 'interface' can't be used as an identifier because it's a keyword.
typedef void interface();
^^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:72:9: Expected an identifier, but got 'interface'.
+parser/error_recovery/keyword_named_typedefs:72:9: 'interface' can't be used as an identifier because it's a keyword.
typedef interface = void Function();
^^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:73:14: Expected an identifier, but got 'is'.
+parser/error_recovery/keyword_named_typedefs:73:14: 'is' can't be used as an identifier because it's a keyword.
typedef void is();
^^
-parser/error_recovery/keyword_named_typedefs:74:9: Expected an identifier, but got 'is'.
+parser/error_recovery/keyword_named_typedefs:74:9: 'is' can't be used as an identifier because it's a keyword.
typedef is = void Function();
^^
-parser/error_recovery/keyword_named_typedefs:75:14: Expected an identifier, but got 'late'.
+parser/error_recovery/keyword_named_typedefs:75:14: 'late' can't be used as an identifier because it's a keyword.
typedef void late();
^^^^
-parser/error_recovery/keyword_named_typedefs:76:9: Expected an identifier, but got 'late'.
+parser/error_recovery/keyword_named_typedefs:76:9: 'late' can't be used as an identifier because it's a keyword.
typedef late = void Function();
^^^^
-parser/error_recovery/keyword_named_typedefs:77:14: Expected an identifier, but got 'library'.
+parser/error_recovery/keyword_named_typedefs:77:14: 'library' can't be used as an identifier because it's a keyword.
typedef void library();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:78:9: Expected an identifier, but got 'library'.
+parser/error_recovery/keyword_named_typedefs:78:9: 'library' can't be used as an identifier because it's a keyword.
typedef library = void Function();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:79:14: Expected an identifier, but got 'mixin'.
+parser/error_recovery/keyword_named_typedefs:79:14: 'mixin' can't be used as an identifier because it's a keyword.
typedef void mixin();
^^^^^
-parser/error_recovery/keyword_named_typedefs:80:9: Expected an identifier, but got 'mixin'.
+parser/error_recovery/keyword_named_typedefs:80:9: 'mixin' can't be used as an identifier because it's a keyword.
typedef mixin = void Function();
^^^^^
-parser/error_recovery/keyword_named_typedefs:83:14: Expected an identifier, but got 'new'.
+parser/error_recovery/keyword_named_typedefs:83:14: 'new' can't be used as an identifier because it's a keyword.
typedef void new();
^^^
-parser/error_recovery/keyword_named_typedefs:84:9: Expected an identifier, but got 'new'.
+parser/error_recovery/keyword_named_typedefs:84:9: 'new' can't be used as an identifier because it's a keyword.
typedef new = void Function();
^^^
-parser/error_recovery/keyword_named_typedefs:85:14: Expected an identifier, but got 'null'.
+parser/error_recovery/keyword_named_typedefs:85:14: 'null' can't be used as an identifier because it's a keyword.
typedef void null();
^^^^
-parser/error_recovery/keyword_named_typedefs:86:9: Expected an identifier, but got 'null'.
+parser/error_recovery/keyword_named_typedefs:86:9: 'null' can't be used as an identifier because it's a keyword.
typedef null = void Function();
^^^^
-parser/error_recovery/keyword_named_typedefs:91:14: Expected an identifier, but got 'operator'.
+parser/error_recovery/keyword_named_typedefs:91:14: 'operator' can't be used as an identifier because it's a keyword.
typedef void operator();
^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:92:9: Expected an identifier, but got 'operator'.
+parser/error_recovery/keyword_named_typedefs:92:9: 'operator' can't be used as an identifier because it's a keyword.
typedef operator = void Function();
^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:95:14: Expected an identifier, but got 'part'.
+parser/error_recovery/keyword_named_typedefs:95:14: 'part' can't be used as an identifier because it's a keyword.
typedef void part();
^^^^
-parser/error_recovery/keyword_named_typedefs:96:9: Expected an identifier, but got 'part'.
+parser/error_recovery/keyword_named_typedefs:96:9: 'part' can't be used as an identifier because it's a keyword.
typedef part = void Function();
^^^^
-parser/error_recovery/keyword_named_typedefs:99:14: Expected an identifier, but got 'required'.
+parser/error_recovery/keyword_named_typedefs:99:14: 'required' can't be used as an identifier because it's a keyword.
typedef void required();
^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:100:9: Expected an identifier, but got 'required'.
+parser/error_recovery/keyword_named_typedefs:100:9: 'required' can't be used as an identifier because it's a keyword.
typedef required = void Function();
^^^^^^^^
-parser/error_recovery/keyword_named_typedefs:101:14: Expected an identifier, but got 'rethrow'.
+parser/error_recovery/keyword_named_typedefs:101:14: 'rethrow' can't be used as an identifier because it's a keyword.
typedef void rethrow();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:102:9: Expected an identifier, but got 'rethrow'.
+parser/error_recovery/keyword_named_typedefs:102:9: 'rethrow' can't be used as an identifier because it's a keyword.
typedef rethrow = void Function();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:103:14: Expected an identifier, but got 'return'.
+parser/error_recovery/keyword_named_typedefs:103:14: 'return' can't be used as an identifier because it's a keyword.
typedef void return();
^^^^^^
-parser/error_recovery/keyword_named_typedefs:104:9: Expected an identifier, but got 'return'.
+parser/error_recovery/keyword_named_typedefs:104:9: 'return' can't be used as an identifier because it's a keyword.
typedef return = void Function();
^^^^^^
-parser/error_recovery/keyword_named_typedefs:105:14: Expected an identifier, but got 'set'.
+parser/error_recovery/keyword_named_typedefs:105:14: 'set' can't be used as an identifier because it's a keyword.
typedef void set();
^^^
-parser/error_recovery/keyword_named_typedefs:106:9: Expected an identifier, but got 'set'.
+parser/error_recovery/keyword_named_typedefs:106:9: 'set' can't be used as an identifier because it's a keyword.
typedef set = void Function();
^^^
-parser/error_recovery/keyword_named_typedefs:111:14: Expected an identifier, but got 'static'.
+parser/error_recovery/keyword_named_typedefs:111:14: 'static' can't be used as an identifier because it's a keyword.
typedef void static();
^^^^^^
-parser/error_recovery/keyword_named_typedefs:112:9: Expected an identifier, but got 'static'.
+parser/error_recovery/keyword_named_typedefs:112:9: 'static' can't be used as an identifier because it's a keyword.
typedef static = void Function();
^^^^^^
-parser/error_recovery/keyword_named_typedefs:113:14: Expected an identifier, but got 'super'.
+parser/error_recovery/keyword_named_typedefs:113:14: 'super' can't be used as an identifier because it's a keyword.
typedef void super();
^^^^^
-parser/error_recovery/keyword_named_typedefs:114:9: Expected an identifier, but got 'super'.
+parser/error_recovery/keyword_named_typedefs:114:9: 'super' can't be used as an identifier because it's a keyword.
typedef super = void Function();
^^^^^
-parser/error_recovery/keyword_named_typedefs:115:14: Expected an identifier, but got 'switch'.
+parser/error_recovery/keyword_named_typedefs:115:14: 'switch' can't be used as an identifier because it's a keyword.
typedef void switch();
^^^^^^
-parser/error_recovery/keyword_named_typedefs:116:9: Expected an identifier, but got 'switch'.
+parser/error_recovery/keyword_named_typedefs:116:9: 'switch' can't be used as an identifier because it's a keyword.
typedef switch = void Function();
^^^^^^
-parser/error_recovery/keyword_named_typedefs:119:14: Expected an identifier, but got 'this'.
+parser/error_recovery/keyword_named_typedefs:119:14: 'this' can't be used as an identifier because it's a keyword.
typedef void this();
^^^^
-parser/error_recovery/keyword_named_typedefs:120:9: Expected an identifier, but got 'this'.
+parser/error_recovery/keyword_named_typedefs:120:9: 'this' can't be used as an identifier because it's a keyword.
typedef this = void Function();
^^^^
-parser/error_recovery/keyword_named_typedefs:121:14: Expected an identifier, but got 'throw'.
+parser/error_recovery/keyword_named_typedefs:121:14: 'throw' can't be used as an identifier because it's a keyword.
typedef void throw();
^^^^^
-parser/error_recovery/keyword_named_typedefs:122:9: Expected an identifier, but got 'throw'.
+parser/error_recovery/keyword_named_typedefs:122:9: 'throw' can't be used as an identifier because it's a keyword.
typedef throw = void Function();
^^^^^
-parser/error_recovery/keyword_named_typedefs:123:14: Expected an identifier, but got 'true'.
+parser/error_recovery/keyword_named_typedefs:123:14: 'true' can't be used as an identifier because it's a keyword.
typedef void true();
^^^^
-parser/error_recovery/keyword_named_typedefs:124:9: Expected an identifier, but got 'true'.
+parser/error_recovery/keyword_named_typedefs:124:9: 'true' can't be used as an identifier because it's a keyword.
typedef true = void Function();
^^^^
-parser/error_recovery/keyword_named_typedefs:125:14: Expected an identifier, but got 'try'.
+parser/error_recovery/keyword_named_typedefs:125:14: 'try' can't be used as an identifier because it's a keyword.
typedef void try();
^^^
-parser/error_recovery/keyword_named_typedefs:126:9: Expected an identifier, but got 'try'.
+parser/error_recovery/keyword_named_typedefs:126:9: 'try' can't be used as an identifier because it's a keyword.
typedef try = void Function();
^^^
-parser/error_recovery/keyword_named_typedefs:127:14: Expected an identifier, but got 'typedef'.
+parser/error_recovery/keyword_named_typedefs:127:14: 'typedef' can't be used as an identifier because it's a keyword.
typedef void typedef();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:128:9: Expected an identifier, but got 'typedef'.
+parser/error_recovery/keyword_named_typedefs:128:9: 'typedef' can't be used as an identifier because it's a keyword.
typedef typedef = void Function();
^^^^^^^
-parser/error_recovery/keyword_named_typedefs:129:14: Expected an identifier, but got 'var'.
+parser/error_recovery/keyword_named_typedefs:129:14: 'var' can't be used as an identifier because it's a keyword.
typedef void var();
^^^
-parser/error_recovery/keyword_named_typedefs:130:9: Expected an identifier, but got 'var'.
+parser/error_recovery/keyword_named_typedefs:130:9: 'var' can't be used as an identifier because it's a keyword.
typedef var = void Function();
^^^
-parser/error_recovery/keyword_named_typedefs:131:14: Expected an identifier, but got 'void'.
+parser/error_recovery/keyword_named_typedefs:131:14: 'void' can't be used as an identifier because it's a keyword.
typedef void void();
^^^^
@@ -448,19 +448,19 @@
typedef void = void Function();
^
-parser/error_recovery/keyword_named_typedefs:133:14: Expected an identifier, but got 'while'.
+parser/error_recovery/keyword_named_typedefs:133:14: 'while' can't be used as an identifier because it's a keyword.
typedef void while();
^^^^^
-parser/error_recovery/keyword_named_typedefs:134:9: Expected an identifier, but got 'while'.
+parser/error_recovery/keyword_named_typedefs:134:9: 'while' can't be used as an identifier because it's a keyword.
typedef while = void Function();
^^^^^
-parser/error_recovery/keyword_named_typedefs:135:14: Expected an identifier, but got 'with'.
+parser/error_recovery/keyword_named_typedefs:135:14: 'with' can't be used as an identifier because it's a keyword.
typedef void with();
^^^^
-parser/error_recovery/keyword_named_typedefs:136:9: Expected an identifier, but got 'with'.
+parser/error_recovery/keyword_named_typedefs:136:9: 'with' can't be used as an identifier because it's a keyword.
typedef with = void Function();
^^^^
@@ -470,7 +470,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'abstract'., null, {token: abstract}], abstract, abstract)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'abstract' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: abstract}], abstract, abstract)
handleIdentifier(abstract, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -481,7 +481,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'abstract'., null, {token: abstract}], abstract, abstract)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'abstract' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: abstract}], abstract, abstract)
handleIdentifier(abstract, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -497,7 +497,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'as'., null, {token: as}], as, as)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'as' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: as}], as, as)
handleIdentifier(as, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -508,7 +508,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'as'., null, {token: as}], as, as)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'as' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: as}], as, as)
handleIdentifier(as, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -524,7 +524,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'assert'., null, {token: assert}], assert, assert)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'assert' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: assert}], assert, assert)
handleIdentifier(assert, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -535,7 +535,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'assert'., null, {token: assert}], assert, assert)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'assert' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: assert}], assert, assert)
handleIdentifier(assert, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -601,7 +601,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'break' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: break}], break, break)
handleIdentifier(break, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -612,7 +612,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'break' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: break}], break, break)
handleIdentifier(break, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -628,7 +628,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
handleIdentifier(case, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -639,7 +639,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
handleIdentifier(case, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -655,7 +655,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
handleIdentifier(catch, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -666,7 +666,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
handleIdentifier(catch, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -682,7 +682,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
handleIdentifier(class, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -693,7 +693,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
handleIdentifier(class, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -709,7 +709,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'const'., null, {token: const}], const, const)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'const' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: const}], const, const)
handleIdentifier(const, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -720,7 +720,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'const'., null, {token: const}], const, const)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'const' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: const}], const, const)
handleIdentifier(const, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -736,7 +736,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'continue' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: continue}], continue, continue)
handleIdentifier(continue, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -747,7 +747,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'continue' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: continue}], continue, continue)
handleIdentifier(continue, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -763,7 +763,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'covariant'., null, {token: covariant}], covariant, covariant)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'covariant' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: covariant}], covariant, covariant)
handleIdentifier(covariant, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -774,7 +774,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'covariant'., null, {token: covariant}], covariant, covariant)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'covariant' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: covariant}], covariant, covariant)
handleIdentifier(covariant, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -790,7 +790,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
handleIdentifier(default, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -801,7 +801,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
handleIdentifier(default, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -817,7 +817,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'deferred'., null, {token: deferred}], deferred, deferred)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'deferred' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: deferred}], deferred, deferred)
handleIdentifier(deferred, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -828,7 +828,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'deferred'., null, {token: deferred}], deferred, deferred)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'deferred' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: deferred}], deferred, deferred)
handleIdentifier(deferred, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -844,7 +844,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'do' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: do}], do, do)
handleIdentifier(do, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -855,7 +855,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'do' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: do}], do, do)
handleIdentifier(do, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -871,7 +871,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'dynamic'., null, {token: dynamic}], dynamic, dynamic)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'dynamic' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: dynamic}], dynamic, dynamic)
handleIdentifier(dynamic, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -882,7 +882,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'dynamic'., null, {token: dynamic}], dynamic, dynamic)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'dynamic' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: dynamic}], dynamic, dynamic)
handleIdentifier(dynamic, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -898,7 +898,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'else' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: else}], else, else)
handleIdentifier(else, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -909,7 +909,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'else' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: else}], else, else)
handleIdentifier(else, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -925,7 +925,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
handleIdentifier(enum, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -936,7 +936,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
handleIdentifier(enum, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -952,7 +952,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'export'., null, {token: export}], export, export)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'export' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: export}], export, export)
handleIdentifier(export, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -963,7 +963,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'export'., null, {token: export}], export, export)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'export' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: export}], export, export)
handleIdentifier(export, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -979,7 +979,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
handleIdentifier(extends, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -990,7 +990,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
handleIdentifier(extends, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1006,7 +1006,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extension'., null, {token: extension}], extension, extension)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extension' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extension}], extension, extension)
handleIdentifier(extension, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1017,7 +1017,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extension'., null, {token: extension}], extension, extension)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extension' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extension}], extension, extension)
handleIdentifier(extension, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1033,7 +1033,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'external'., null, {token: external}], external, external)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'external' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: external}], external, external)
handleIdentifier(external, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1044,7 +1044,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'external'., null, {token: external}], external, external)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'external' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: external}], external, external)
handleIdentifier(external, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1060,7 +1060,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'factory'., null, {token: factory}], factory, factory)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'factory' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: factory}], factory, factory)
handleIdentifier(factory, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1071,7 +1071,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'factory'., null, {token: factory}], factory, factory)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'factory' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: factory}], factory, factory)
handleIdentifier(factory, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1087,7 +1087,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'false'., null, {token: false}], false, false)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'false' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: false}], false, false)
handleIdentifier(false, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1098,7 +1098,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'false'., null, {token: false}], false, false)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'false' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: false}], false, false)
handleIdentifier(false, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1114,7 +1114,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'final' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: final}], final, final)
handleIdentifier(final, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1125,7 +1125,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'final' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: final}], final, final)
handleIdentifier(final, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1141,7 +1141,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
handleIdentifier(finally, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1152,7 +1152,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
handleIdentifier(finally, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1168,7 +1168,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'for' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: for}], for, for)
handleIdentifier(for, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1179,7 +1179,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'for' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: for}], for, for)
handleIdentifier(for, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1195,7 +1195,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'Function'., null, {token: Function}], Function, Function)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'Function' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: Function}], Function, Function)
handleIdentifier(Function, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1206,7 +1206,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'Function'., null, {token: Function}], Function, Function)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'Function' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: Function}], Function, Function)
handleIdentifier(Function, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1222,7 +1222,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'get'., null, {token: get}], get, get)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'get' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: get}], get, get)
handleIdentifier(get, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1233,7 +1233,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'get'., null, {token: get}], get, get)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'get' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: get}], get, get)
handleIdentifier(get, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1274,7 +1274,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'if' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: if}], if, if)
handleIdentifier(if, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1285,7 +1285,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'if' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: if}], if, if)
handleIdentifier(if, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1301,7 +1301,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'implements'., null, {token: implements}], implements, implements)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'implements' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: implements}], implements, implements)
handleIdentifier(implements, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1312,7 +1312,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'implements'., null, {token: implements}], implements, implements)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'implements' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: implements}], implements, implements)
handleIdentifier(implements, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1328,7 +1328,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'import'., null, {token: import}], import, import)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'import' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: import}], import, import)
handleIdentifier(import, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1339,7 +1339,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'import'., null, {token: import}], import, import)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'import' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: import}], import, import)
handleIdentifier(import, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1355,7 +1355,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
handleIdentifier(in, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1366,7 +1366,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
handleIdentifier(in, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1407,7 +1407,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'interface'., null, {token: interface}], interface, interface)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'interface' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: interface}], interface, interface)
handleIdentifier(interface, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1418,7 +1418,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'interface'., null, {token: interface}], interface, interface)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'interface' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: interface}], interface, interface)
handleIdentifier(interface, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1434,7 +1434,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'is' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: is}], is, is)
handleIdentifier(is, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1445,7 +1445,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'is' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: is}], is, is)
handleIdentifier(is, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1461,7 +1461,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'late'., null, {token: late}], late, late)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'late' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: late}], late, late)
handleIdentifier(late, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1472,7 +1472,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'late'., null, {token: late}], late, late)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'late' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: late}], late, late)
handleIdentifier(late, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1488,7 +1488,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'library'., null, {token: library}], library, library)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'library' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: library}], library, library)
handleIdentifier(library, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1499,7 +1499,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'library'., null, {token: library}], library, library)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'library' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: library}], library, library)
handleIdentifier(library, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1515,7 +1515,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'mixin'., null, {token: mixin}], mixin, mixin)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'mixin' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: mixin}], mixin, mixin)
handleIdentifier(mixin, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1526,7 +1526,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'mixin'., null, {token: mixin}], mixin, mixin)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'mixin' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: mixin}], mixin, mixin)
handleIdentifier(mixin, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1567,7 +1567,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'new'., null, {token: new}], new, new)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'new' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: new}], new, new)
handleIdentifier(new, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1578,7 +1578,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'new'., null, {token: new}], new, new)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'new' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: new}], new, new)
handleIdentifier(new, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1594,7 +1594,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'null'., null, {token: null}], null, null)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'null' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: null}], null, null)
handleIdentifier(null, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1605,7 +1605,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'null'., null, {token: null}], null, null)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'null' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: null}], null, null)
handleIdentifier(null, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1671,7 +1671,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'operator'., null, {token: operator}], operator, operator)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'operator' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: operator}], operator, operator)
handleIdentifier(operator, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1682,7 +1682,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'operator'., null, {token: operator}], operator, operator)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'operator' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: operator}], operator, operator)
handleIdentifier(operator, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1723,7 +1723,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'part'., null, {token: part}], part, part)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'part' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: part}], part, part)
handleIdentifier(part, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1734,7 +1734,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'part'., null, {token: part}], part, part)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'part' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: part}], part, part)
handleIdentifier(part, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1775,7 +1775,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'required'., null, {token: required}], required, required)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'required' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: required}], required, required)
handleIdentifier(required, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1786,7 +1786,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'required'., null, {token: required}], required, required)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'required' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: required}], required, required)
handleIdentifier(required, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1802,7 +1802,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
handleIdentifier(rethrow, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1813,7 +1813,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
handleIdentifier(rethrow, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1829,7 +1829,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'return'., null, {token: return}], return, return)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'return' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: return}], return, return)
handleIdentifier(return, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1840,7 +1840,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'return'., null, {token: return}], return, return)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'return' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: return}], return, return)
handleIdentifier(return, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1856,7 +1856,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'set'., null, {token: set}], set, set)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'set' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: set}], set, set)
handleIdentifier(set, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1867,7 +1867,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'set'., null, {token: set}], set, set)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'set' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: set}], set, set)
handleIdentifier(set, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1933,7 +1933,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'static'., null, {token: static}], static, static)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'static' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: static}], static, static)
handleIdentifier(static, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1944,7 +1944,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'static'., null, {token: static}], static, static)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'static' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: static}], static, static)
handleIdentifier(static, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1960,7 +1960,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'super'., null, {token: super}], super, super)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'super' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: super}], super, super)
handleIdentifier(super, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1971,7 +1971,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'super'., null, {token: super}], super, super)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'super' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: super}], super, super)
handleIdentifier(super, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -1987,7 +1987,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'switch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: switch}], switch, switch)
handleIdentifier(switch, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -1998,7 +1998,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'switch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: switch}], switch, switch)
handleIdentifier(switch, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -2039,7 +2039,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'this' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: this}], this, this)
handleIdentifier(this, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -2050,7 +2050,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'this' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: this}], this, this)
handleIdentifier(this, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -2066,7 +2066,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'throw'., null, {token: throw}], throw, throw)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'throw' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: throw}], throw, throw)
handleIdentifier(throw, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -2077,7 +2077,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'throw'., null, {token: throw}], throw, throw)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'throw' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: throw}], throw, throw)
handleIdentifier(throw, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -2093,7 +2093,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'true'., null, {token: true}], true, true)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'true' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: true}], true, true)
handleIdentifier(true, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -2104,7 +2104,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'true'., null, {token: true}], true, true)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'true' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: true}], true, true)
handleIdentifier(true, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -2120,7 +2120,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'try' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: try}], try, try)
handleIdentifier(try, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -2131,7 +2131,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'try' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: try}], try, try)
handleIdentifier(try, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -2147,7 +2147,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'typedef'., null, {token: typedef}], typedef, typedef)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'typedef' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: typedef}], typedef, typedef)
handleIdentifier(typedef, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -2158,7 +2158,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'typedef'., null, {token: typedef}], typedef, typedef)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'typedef' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: typedef}], typedef, typedef)
handleIdentifier(typedef, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -2174,7 +2174,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'var' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: var}], var, var)
handleIdentifier(var, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -2185,7 +2185,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'var' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: var}], var, var)
handleIdentifier(var, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -2201,7 +2201,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'void' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: void}], void, void)
handleIdentifier(void, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -2213,7 +2213,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '='., null, {token: =}], =, =)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '='., Try inserting an identifier before '='., {token: =}], =, =)
handleIdentifier(, typedefDeclaration)
handleNoTypeVariables(=)
handleRecoverableError(MissingTypedefParameters, =, =)
@@ -2247,7 +2247,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'while' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: while}], while, while)
handleIdentifier(while, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -2258,7 +2258,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'while' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: while}], while, while)
handleIdentifier(while, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
@@ -2274,7 +2274,7 @@
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
handleIdentifier(with, typedefDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.FunctionTypeAlias)
@@ -2285,7 +2285,7 @@
endMetadataStar(0)
beginUncategorizedTopLevelDeclaration(typedef)
beginFunctionTypeAlias(typedef)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
handleIdentifier(with, typedefDeclaration)
handleNoTypeVariables(=)
beginFunctionType(void)
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_typedefs.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_typedefs.dart.intertwined.expect
index 6802b71..cc71477 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_typedefs.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_typedefs.dart.intertwined.expect
@@ -14,7 +14,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(abstract, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'abstract'., null, {token: abstract}], abstract, abstract)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'abstract' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: abstract}], abstract, abstract)
listener: handleIdentifier(abstract, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(abstract, MemberKind.FunctionTypeAlias)
@@ -35,7 +35,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(abstract, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'abstract'., null, {token: abstract}], abstract, abstract)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'abstract' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: abstract}], abstract, abstract)
listener: handleIdentifier(abstract, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -61,7 +61,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(as, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'as'., null, {token: as}], as, as)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'as' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: as}], as, as)
listener: handleIdentifier(as, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(as, MemberKind.FunctionTypeAlias)
@@ -82,7 +82,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(as, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'as'., null, {token: as}], as, as)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'as' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: as}], as, as)
listener: handleIdentifier(as, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -108,7 +108,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(assert, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'assert'., null, {token: assert}], assert, assert)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'assert' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: assert}], assert, assert)
listener: handleIdentifier(assert, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(assert, MemberKind.FunctionTypeAlias)
@@ -129,7 +129,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(assert, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'assert'., null, {token: assert}], assert, assert)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'assert' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: assert}], assert, assert)
listener: handleIdentifier(assert, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -241,7 +241,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(break, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'break' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: break}], break, break)
listener: handleIdentifier(break, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(break, MemberKind.FunctionTypeAlias)
@@ -262,7 +262,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(break, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'break' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: break}], break, break)
listener: handleIdentifier(break, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -288,7 +288,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(case, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
listener: handleIdentifier(case, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(case, MemberKind.FunctionTypeAlias)
@@ -309,7 +309,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(case, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'case' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: case}], case, case)
listener: handleIdentifier(case, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -335,7 +335,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(catch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
listener: handleIdentifier(catch, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(catch, MemberKind.FunctionTypeAlias)
@@ -356,7 +356,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(catch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'catch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: catch}], catch, catch)
listener: handleIdentifier(catch, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -382,7 +382,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(class, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
listener: handleIdentifier(class, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(class, MemberKind.FunctionTypeAlias)
@@ -403,7 +403,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(class, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'class' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: class}], class, class)
listener: handleIdentifier(class, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -429,7 +429,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(const, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'const'., null, {token: const}], const, const)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'const' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: const}], const, const)
listener: handleIdentifier(const, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(const, MemberKind.FunctionTypeAlias)
@@ -450,7 +450,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(const, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'const'., null, {token: const}], const, const)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'const' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: const}], const, const)
listener: handleIdentifier(const, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -476,7 +476,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(continue, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'continue' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: continue}], continue, continue)
listener: handleIdentifier(continue, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(continue, MemberKind.FunctionTypeAlias)
@@ -497,7 +497,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(continue, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'continue' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: continue}], continue, continue)
listener: handleIdentifier(continue, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -523,7 +523,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(covariant, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'covariant'., null, {token: covariant}], covariant, covariant)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'covariant' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: covariant}], covariant, covariant)
listener: handleIdentifier(covariant, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(covariant, MemberKind.FunctionTypeAlias)
@@ -544,7 +544,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(covariant, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'covariant'., null, {token: covariant}], covariant, covariant)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'covariant' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: covariant}], covariant, covariant)
listener: handleIdentifier(covariant, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -570,7 +570,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(default, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
listener: handleIdentifier(default, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(default, MemberKind.FunctionTypeAlias)
@@ -591,7 +591,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(default, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'default' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: default}], default, default)
listener: handleIdentifier(default, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -617,7 +617,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(deferred, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'deferred'., null, {token: deferred}], deferred, deferred)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'deferred' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: deferred}], deferred, deferred)
listener: handleIdentifier(deferred, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(deferred, MemberKind.FunctionTypeAlias)
@@ -638,7 +638,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(deferred, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'deferred'., null, {token: deferred}], deferred, deferred)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'deferred' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: deferred}], deferred, deferred)
listener: handleIdentifier(deferred, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -664,7 +664,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(do, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'do' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: do}], do, do)
listener: handleIdentifier(do, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(do, MemberKind.FunctionTypeAlias)
@@ -685,7 +685,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(do, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'do' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: do}], do, do)
listener: handleIdentifier(do, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -711,7 +711,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(dynamic, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'dynamic'., null, {token: dynamic}], dynamic, dynamic)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'dynamic' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: dynamic}], dynamic, dynamic)
listener: handleIdentifier(dynamic, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(dynamic, MemberKind.FunctionTypeAlias)
@@ -732,7 +732,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(dynamic, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'dynamic'., null, {token: dynamic}], dynamic, dynamic)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'dynamic' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: dynamic}], dynamic, dynamic)
listener: handleIdentifier(dynamic, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -758,7 +758,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(else, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'else' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: else}], else, else)
listener: handleIdentifier(else, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(else, MemberKind.FunctionTypeAlias)
@@ -779,7 +779,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(else, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'else' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: else}], else, else)
listener: handleIdentifier(else, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -805,7 +805,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(enum, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
listener: handleIdentifier(enum, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(enum, MemberKind.FunctionTypeAlias)
@@ -826,7 +826,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(enum, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'enum' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: enum}], enum, enum)
listener: handleIdentifier(enum, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -852,7 +852,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(export, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'export'., null, {token: export}], export, export)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'export' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: export}], export, export)
listener: handleIdentifier(export, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(export, MemberKind.FunctionTypeAlias)
@@ -873,7 +873,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(export, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'export'., null, {token: export}], export, export)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'export' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: export}], export, export)
listener: handleIdentifier(export, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -899,7 +899,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(extends, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
listener: handleIdentifier(extends, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(extends, MemberKind.FunctionTypeAlias)
@@ -920,7 +920,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(extends, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extends' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extends}], extends, extends)
listener: handleIdentifier(extends, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -946,7 +946,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(extension, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extension'., null, {token: extension}], extension, extension)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extension' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extension}], extension, extension)
listener: handleIdentifier(extension, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(extension, MemberKind.FunctionTypeAlias)
@@ -967,7 +967,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(extension, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extension'., null, {token: extension}], extension, extension)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'extension' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: extension}], extension, extension)
listener: handleIdentifier(extension, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -993,7 +993,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(external, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'external'., null, {token: external}], external, external)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'external' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: external}], external, external)
listener: handleIdentifier(external, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(external, MemberKind.FunctionTypeAlias)
@@ -1014,7 +1014,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(external, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'external'., null, {token: external}], external, external)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'external' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: external}], external, external)
listener: handleIdentifier(external, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1040,7 +1040,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(factory, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'factory'., null, {token: factory}], factory, factory)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'factory' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: factory}], factory, factory)
listener: handleIdentifier(factory, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(factory, MemberKind.FunctionTypeAlias)
@@ -1061,7 +1061,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(factory, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'factory'., null, {token: factory}], factory, factory)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'factory' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: factory}], factory, factory)
listener: handleIdentifier(factory, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1087,7 +1087,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(false, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'false'., null, {token: false}], false, false)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'false' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: false}], false, false)
listener: handleIdentifier(false, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(false, MemberKind.FunctionTypeAlias)
@@ -1108,7 +1108,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(false, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'false'., null, {token: false}], false, false)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'false' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: false}], false, false)
listener: handleIdentifier(false, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1134,7 +1134,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(final, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'final' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: final}], final, final)
listener: handleIdentifier(final, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(final, MemberKind.FunctionTypeAlias)
@@ -1155,7 +1155,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(final, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'final' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: final}], final, final)
listener: handleIdentifier(final, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1181,7 +1181,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(finally, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
listener: handleIdentifier(finally, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(finally, MemberKind.FunctionTypeAlias)
@@ -1202,7 +1202,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(finally, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'finally' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: finally}], finally, finally)
listener: handleIdentifier(finally, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1228,7 +1228,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(for, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'for' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: for}], for, for)
listener: handleIdentifier(for, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(for, MemberKind.FunctionTypeAlias)
@@ -1249,7 +1249,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(for, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'for' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: for}], for, for)
listener: handleIdentifier(for, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1275,7 +1275,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(Function, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'Function'., null, {token: Function}], Function, Function)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'Function' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: Function}], Function, Function)
listener: handleIdentifier(Function, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(Function, MemberKind.FunctionTypeAlias)
@@ -1296,7 +1296,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(Function, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'Function'., null, {token: Function}], Function, Function)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'Function' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: Function}], Function, Function)
listener: handleIdentifier(Function, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1322,7 +1322,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(get, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'get'., null, {token: get}], get, get)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'get' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: get}], get, get)
listener: handleIdentifier(get, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(get, MemberKind.FunctionTypeAlias)
@@ -1343,7 +1343,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(get, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'get'., null, {token: get}], get, get)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'get' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: get}], get, get)
listener: handleIdentifier(get, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1412,7 +1412,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(if, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'if' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: if}], if, if)
listener: handleIdentifier(if, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(if, MemberKind.FunctionTypeAlias)
@@ -1433,7 +1433,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(if, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'if' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: if}], if, if)
listener: handleIdentifier(if, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1459,7 +1459,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(implements, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'implements'., null, {token: implements}], implements, implements)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'implements' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: implements}], implements, implements)
listener: handleIdentifier(implements, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(implements, MemberKind.FunctionTypeAlias)
@@ -1480,7 +1480,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(implements, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'implements'., null, {token: implements}], implements, implements)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'implements' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: implements}], implements, implements)
listener: handleIdentifier(implements, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1506,7 +1506,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(import, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'import'., null, {token: import}], import, import)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'import' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: import}], import, import)
listener: handleIdentifier(import, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(import, MemberKind.FunctionTypeAlias)
@@ -1527,7 +1527,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(import, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'import'., null, {token: import}], import, import)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'import' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: import}], import, import)
listener: handleIdentifier(import, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1553,7 +1553,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(in, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
listener: handleIdentifier(in, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(in, MemberKind.FunctionTypeAlias)
@@ -1574,7 +1574,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(in, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'in' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: in}], in, in)
listener: handleIdentifier(in, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1643,7 +1643,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(interface, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'interface'., null, {token: interface}], interface, interface)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'interface' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: interface}], interface, interface)
listener: handleIdentifier(interface, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(interface, MemberKind.FunctionTypeAlias)
@@ -1664,7 +1664,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(interface, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'interface'., null, {token: interface}], interface, interface)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'interface' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: interface}], interface, interface)
listener: handleIdentifier(interface, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1690,7 +1690,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(is, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'is' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: is}], is, is)
listener: handleIdentifier(is, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(is, MemberKind.FunctionTypeAlias)
@@ -1711,7 +1711,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(is, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'is' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: is}], is, is)
listener: handleIdentifier(is, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1737,7 +1737,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(late, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'late'., null, {token: late}], late, late)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'late' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: late}], late, late)
listener: handleIdentifier(late, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(late, MemberKind.FunctionTypeAlias)
@@ -1758,7 +1758,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(late, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'late'., null, {token: late}], late, late)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'late' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: late}], late, late)
listener: handleIdentifier(late, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1784,7 +1784,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(library, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'library'., null, {token: library}], library, library)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'library' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: library}], library, library)
listener: handleIdentifier(library, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(library, MemberKind.FunctionTypeAlias)
@@ -1805,7 +1805,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(library, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'library'., null, {token: library}], library, library)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'library' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: library}], library, library)
listener: handleIdentifier(library, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1831,7 +1831,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(mixin, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'mixin'., null, {token: mixin}], mixin, mixin)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'mixin' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: mixin}], mixin, mixin)
listener: handleIdentifier(mixin, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(mixin, MemberKind.FunctionTypeAlias)
@@ -1852,7 +1852,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(mixin, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'mixin'., null, {token: mixin}], mixin, mixin)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'mixin' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: mixin}], mixin, mixin)
listener: handleIdentifier(mixin, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1921,7 +1921,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(new, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'new'., null, {token: new}], new, new)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'new' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: new}], new, new)
listener: handleIdentifier(new, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(new, MemberKind.FunctionTypeAlias)
@@ -1942,7 +1942,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(new, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'new'., null, {token: new}], new, new)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'new' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: new}], new, new)
listener: handleIdentifier(new, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -1968,7 +1968,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(null, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'null'., null, {token: null}], null, null)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'null' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: null}], null, null)
listener: handleIdentifier(null, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(null, MemberKind.FunctionTypeAlias)
@@ -1989,7 +1989,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(null, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'null'., null, {token: null}], null, null)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'null' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: null}], null, null)
listener: handleIdentifier(null, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2101,7 +2101,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(operator, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'operator'., null, {token: operator}], operator, operator)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'operator' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: operator}], operator, operator)
listener: handleIdentifier(operator, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(operator, MemberKind.FunctionTypeAlias)
@@ -2122,7 +2122,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(operator, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'operator'., null, {token: operator}], operator, operator)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'operator' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: operator}], operator, operator)
listener: handleIdentifier(operator, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2191,7 +2191,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(part, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'part'., null, {token: part}], part, part)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'part' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: part}], part, part)
listener: handleIdentifier(part, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(part, MemberKind.FunctionTypeAlias)
@@ -2212,7 +2212,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(part, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'part'., null, {token: part}], part, part)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'part' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: part}], part, part)
listener: handleIdentifier(part, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2281,7 +2281,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(required, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'required'., null, {token: required}], required, required)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'required' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: required}], required, required)
listener: handleIdentifier(required, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(required, MemberKind.FunctionTypeAlias)
@@ -2302,7 +2302,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(required, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'required'., null, {token: required}], required, required)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'required' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: required}], required, required)
listener: handleIdentifier(required, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2328,7 +2328,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(rethrow, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
listener: handleIdentifier(rethrow, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(rethrow, MemberKind.FunctionTypeAlias)
@@ -2349,7 +2349,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(rethrow, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'rethrow' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: rethrow}], rethrow, rethrow)
listener: handleIdentifier(rethrow, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2375,7 +2375,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(return, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'return'., null, {token: return}], return, return)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'return' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: return}], return, return)
listener: handleIdentifier(return, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(return, MemberKind.FunctionTypeAlias)
@@ -2396,7 +2396,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(return, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'return'., null, {token: return}], return, return)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'return' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: return}], return, return)
listener: handleIdentifier(return, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2422,7 +2422,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(set, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'set'., null, {token: set}], set, set)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'set' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: set}], set, set)
listener: handleIdentifier(set, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(set, MemberKind.FunctionTypeAlias)
@@ -2443,7 +2443,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(set, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'set'., null, {token: set}], set, set)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'set' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: set}], set, set)
listener: handleIdentifier(set, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2555,7 +2555,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(static, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'static'., null, {token: static}], static, static)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'static' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: static}], static, static)
listener: handleIdentifier(static, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(static, MemberKind.FunctionTypeAlias)
@@ -2576,7 +2576,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(static, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'static'., null, {token: static}], static, static)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'static' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: static}], static, static)
listener: handleIdentifier(static, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2602,7 +2602,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(super, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'super'., null, {token: super}], super, super)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'super' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: super}], super, super)
listener: handleIdentifier(super, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(super, MemberKind.FunctionTypeAlias)
@@ -2623,7 +2623,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(super, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'super'., null, {token: super}], super, super)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'super' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: super}], super, super)
listener: handleIdentifier(super, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2649,7 +2649,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(switch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'switch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: switch}], switch, switch)
listener: handleIdentifier(switch, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(switch, MemberKind.FunctionTypeAlias)
@@ -2670,7 +2670,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(switch, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'switch' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: switch}], switch, switch)
listener: handleIdentifier(switch, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2739,7 +2739,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(this, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'this' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: this}], this, this)
listener: handleIdentifier(this, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(this, MemberKind.FunctionTypeAlias)
@@ -2760,7 +2760,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(this, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'this' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: this}], this, this)
listener: handleIdentifier(this, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2786,7 +2786,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(throw, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'throw'., null, {token: throw}], throw, throw)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'throw' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: throw}], throw, throw)
listener: handleIdentifier(throw, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(throw, MemberKind.FunctionTypeAlias)
@@ -2807,7 +2807,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(throw, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'throw'., null, {token: throw}], throw, throw)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'throw' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: throw}], throw, throw)
listener: handleIdentifier(throw, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2833,7 +2833,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(true, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'true'., null, {token: true}], true, true)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'true' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: true}], true, true)
listener: handleIdentifier(true, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(true, MemberKind.FunctionTypeAlias)
@@ -2854,7 +2854,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(true, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'true'., null, {token: true}], true, true)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'true' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: true}], true, true)
listener: handleIdentifier(true, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2880,7 +2880,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(try, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'try' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: try}], try, try)
listener: handleIdentifier(try, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(try, MemberKind.FunctionTypeAlias)
@@ -2901,7 +2901,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(try, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'try' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: try}], try, try)
listener: handleIdentifier(try, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2927,7 +2927,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(typedef, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'typedef'., null, {token: typedef}], typedef, typedef)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'typedef' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: typedef}], typedef, typedef)
listener: handleIdentifier(typedef, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(typedef, MemberKind.FunctionTypeAlias)
@@ -2948,7 +2948,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(typedef, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'typedef'., null, {token: typedef}], typedef, typedef)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'typedef' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: typedef}], typedef, typedef)
listener: handleIdentifier(typedef, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -2974,7 +2974,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(var, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'var' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: var}], var, var)
listener: handleIdentifier(var, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(var, MemberKind.FunctionTypeAlias)
@@ -2995,7 +2995,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(var, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'var' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: var}], var, var)
listener: handleIdentifier(var, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -3021,7 +3021,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(void, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'void' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: void}], void, void)
listener: handleIdentifier(void, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(void, MemberKind.FunctionTypeAlias)
@@ -3042,9 +3042,9 @@
listener: beginFunctionTypeAlias(typedef)
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, false)
- insertSyntheticIdentifier(void, typedefDeclaration, message: Message[ExpectedIdentifier, Expected an identifier, but got '='., null, {token: =}], messageOnToken: null)
- reportRecoverableError(=, Message[ExpectedIdentifier, Expected an identifier, but got '='., null, {token: =}])
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '='., null, {token: =}], =, =)
+ insertSyntheticIdentifier(void, typedefDeclaration, message: Message[ExpectedIdentifier, Expected an identifier, but got '='., Try inserting an identifier before '='., {token: =}], messageOnToken: null)
+ reportRecoverableError(=, Message[ExpectedIdentifier, Expected an identifier, but got '='., Try inserting an identifier before '='., {token: =}])
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '='., Try inserting an identifier before '='., {token: =}], =, =)
rewriter()
listener: handleIdentifier(, typedefDeclaration)
listener: handleNoTypeVariables(=)
@@ -3111,7 +3111,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(while, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'while' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: while}], while, while)
listener: handleIdentifier(while, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(while, MemberKind.FunctionTypeAlias)
@@ -3132,7 +3132,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(while, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'while' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: while}], while, while)
listener: handleIdentifier(while, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
@@ -3158,7 +3158,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(void, typedefDeclaration, true)
reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
listener: handleIdentifier(with, typedefDeclaration)
listener: handleNoTypeVariables(()
parseFormalParametersRequiredOpt(with, MemberKind.FunctionTypeAlias)
@@ -3179,7 +3179,7 @@
listener: beginFunctionTypeAlias(typedef)
ensureIdentifierPotentiallyRecovered(typedef, typedefDeclaration, true)
reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
listener: handleIdentifier(with, typedefDeclaration)
listener: handleNoTypeVariables(=)
listener: beginFunctionType(void)
diff --git a/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.expect b/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.expect
index 24b5d80..a86e853 100644
--- a/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.expect
@@ -1,26 +1,26 @@
Problems reported:
-parser/error_recovery/method_called_with:2:7: Expected an identifier, but got 'with'.
+parser/error_recovery/method_called_with:2:7: 'with' can't be used as an identifier because it's a keyword.
int with() => 7;
^^^^
-parser/error_recovery/method_called_with:3:7: Expected an identifier, but got 'with'.
+parser/error_recovery/method_called_with:3:7: 'with' can't be used as an identifier because it's a keyword.
int with = 7;
^^^^
-parser/error_recovery/method_called_with:4:11: Expected an identifier, but got 'with'.
+parser/error_recovery/method_called_with:4:11: 'with' can't be used as an identifier because it's a keyword.
int get with => 7;
^^^^
-parser/error_recovery/method_called_with:5:12: Expected an identifier, but got 'with'.
+parser/error_recovery/method_called_with:5:12: 'with' can't be used as an identifier because it's a keyword.
void set with(int x) {}
^^^^
-parser/error_recovery/method_called_with:8:5: Expected an identifier, but got 'with'.
+parser/error_recovery/method_called_with:8:5: 'with' can't be used as an identifier because it's a keyword.
int with() => 7;
^^^^
-parser/error_recovery/method_called_with:9:5: Expected an identifier, but got 'with'.
+parser/error_recovery/method_called_with:9:5: 'with' can't be used as an identifier because it's a keyword.
int with = 7;
^^^^
@@ -44,7 +44,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(with)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
handleIdentifier(with, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -62,7 +62,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(with)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
handleIdentifier(with, fieldDeclaration)
beginFieldInitializer(=)
handleLiteralInt(7)
@@ -76,7 +76,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(get)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
handleIdentifier(with, methodDeclaration)
handleNoTypeVariables(=>)
handleNoFormalParameters(=>, MemberKind.NonStaticMethod)
@@ -91,7 +91,7 @@
beginMember()
beginMethod(null, null, null, null, set, with)
handleVoidKeyword(void)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
handleIdentifier(with, methodDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.NonStaticMethod)
@@ -121,7 +121,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(with)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
handleIdentifier(with, topLevelFunctionDeclaration)
handleNoTypeVariables(()
beginFormalParameters((, MemberKind.TopLevelMethod)
@@ -138,7 +138,7 @@
handleIdentifier(int, typeReference)
handleNoTypeArguments(with)
handleType(int, null)
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
handleIdentifier(with, topLevelVariableDeclaration)
beginFieldInitializer(=)
handleLiteralInt(7)
diff --git a/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.intertwined.expect
index 4ff4bb0..4c53a03 100644
--- a/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.intertwined.expect
@@ -41,7 +41,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, methodDeclaration, true)
reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
listener: handleIdentifier(with, methodDeclaration)
parseQualifiedRestOpt(with, methodDeclarationContinuation)
parseMethodTypeVar(with)
@@ -85,7 +85,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, true)
reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
listener: handleIdentifier(with, fieldDeclaration)
parseFieldInitializerOpt(with, with, null, null, null, null, DeclarationKind.Class, C)
listener: beginFieldInitializer(=)
@@ -113,7 +113,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(get, methodDeclaration, true)
reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
listener: handleIdentifier(with, methodDeclaration)
parseQualifiedRestOpt(with, methodDeclarationContinuation)
listener: handleNoTypeVariables(=>)
@@ -152,7 +152,7 @@
listener: handleVoidKeyword(void)
ensureIdentifierPotentiallyRecovered(set, methodDeclaration, true)
reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
listener: handleIdentifier(with, methodDeclaration)
parseQualifiedRestOpt(with, methodDeclarationContinuation)
listener: handleNoTypeVariables(()
@@ -205,7 +205,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelFunctionDeclaration, true)
reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
listener: handleIdentifier(with, topLevelFunctionDeclaration)
parseMethodTypeVar(with)
listener: handleNoTypeVariables(()
@@ -245,7 +245,7 @@
listener: handleType(int, null)
ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, true)
reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
+ listener: handleRecoverableError(Message[ExpectedIdentifierButGotKeyword, 'with' can't be used as an identifier because it's a keyword., Try renaming this to be an identifier that isn't a keyword., {token: with}], with, with)
listener: handleIdentifier(with, topLevelVariableDeclaration)
parseFieldInitializerOpt(with, with, null, null, null, null, DeclarationKind.TopLevel, null)
listener: beginFieldInitializer(=)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.expect
index 1990760..088c5a4 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.expect
@@ -60,7 +60,7 @@
handleParenthesizedExpression(()
handleRecoverableError(Message[ExpectedButGot, Expected ':' before this., null, {string: :}], ;, ;)
handleConditionalExpressionColon()
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ';'., null, {token: ;}], ;, ;)
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ';'., Try inserting an identifier before ';'., {token: ;}], ;, ;)
handleIdentifier(, expression)
handleNoTypeArguments(;)
handleNoArguments(;)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.intertwined.expect
index 093950e..5573577 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.intertwined.expect
@@ -153,7 +153,7 @@
parseSend(:, expression)
ensureIdentifier(:, expression)
reportRecoverableErrorWithToken(;, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ';'., null, {token: ;}], ;, ;)
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ';'., Try inserting an identifier before ';'., {token: ;}], ;, ;)
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(;)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.expect
index 0b56e4b..1357097 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.expect
@@ -95,7 +95,7 @@
endFunctionExpression((, })
handleRecoverableError(Message[ExpectedButGot, Expected ':' before this., null, {string: :}], }, })
handleConditionalExpressionColon()
- handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '}'., null, {token: }}], }, })
+ handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '}'., Try inserting an identifier before '}'., {token: }}], }, })
handleIdentifier(, expression)
handleNoTypeArguments(})
handleNoArguments(})
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.intertwined.expect
index 5fdde51..ee731af 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.intertwined.expect
@@ -177,7 +177,7 @@
parseSend(:, expression)
ensureIdentifier(:, expression)
reportRecoverableErrorWithToken(}, Instance of 'Template<(Token) => Message>')
- listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '}'., null, {token: }}], }, })
+ listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '}'., Try inserting an identifier before '}'., {token: }}], }, })
rewriter()
listener: handleIdentifier(, expression)
listener: handleNoTypeArguments(})
diff --git a/pkg/front_end/testcases/expression/invalid.expression.yaml.expect b/pkg/front_end/testcases/expression/invalid.expression.yaml.expect
index 0bf9a2f..7fc40b9 100644
--- a/pkg/front_end/testcases/expression/invalid.expression.yaml.expect
+++ b/pkg/front_end/testcases/expression/invalid.expression.yaml.expect
@@ -3,6 +3,7 @@
*foo(3,
^
org-dartlang-debug:synthetic_debug_expression:1:1: Error: Expected an identifier, but got '*'.
+ Try inserting an identifier before '*'.
*foo(3,
^
org-dartlang-debug:synthetic_debug_expression:1:2: Error: Method not found: 'foo'.
diff --git a/pkg/front_end/testcases/extensions/issue38600.dart.outline.expect b/pkg/front_end/testcases/extensions/issue38600.dart.outline.expect
index ac62e8d..ed495ec 100644
--- a/pkg/front_end/testcases/extensions/issue38600.dart.outline.expect
+++ b/pkg/front_end/testcases/extensions/issue38600.dart.outline.expect
@@ -15,7 +15,8 @@
// extension try<T> on Class<T> {}
// ^^^
//
-// pkg/front_end/testcases/extensions/issue38600.dart:7:11: Error: Expected an identifier, but got 'try'.
+// pkg/front_end/testcases/extensions/issue38600.dart:7:11: Error: 'try' can't be used as an identifier because it's a keyword.
+// Try renaming this to be an identifier that isn't a keyword.
// extension try<T> on Class<T> {}
// ^^^
//
diff --git a/pkg/front_end/testcases/extensions/issue38600.dart.strong.expect b/pkg/front_end/testcases/extensions/issue38600.dart.strong.expect
index 7deee30..373bda2 100644
--- a/pkg/front_end/testcases/extensions/issue38600.dart.strong.expect
+++ b/pkg/front_end/testcases/extensions/issue38600.dart.strong.expect
@@ -15,7 +15,8 @@
// extension try<T> on Class<T> {}
// ^^^
//
-// pkg/front_end/testcases/extensions/issue38600.dart:7:11: Error: Expected an identifier, but got 'try'.
+// pkg/front_end/testcases/extensions/issue38600.dart:7:11: Error: 'try' can't be used as an identifier because it's a keyword.
+// Try renaming this to be an identifier that isn't a keyword.
// extension try<T> on Class<T> {}
// ^^^
//
diff --git a/pkg/front_end/testcases/extensions/issue38600.dart.strong.transformed.expect b/pkg/front_end/testcases/extensions/issue38600.dart.strong.transformed.expect
index 7deee30..373bda2 100644
--- a/pkg/front_end/testcases/extensions/issue38600.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/extensions/issue38600.dart.strong.transformed.expect
@@ -15,7 +15,8 @@
// extension try<T> on Class<T> {}
// ^^^
//
-// pkg/front_end/testcases/extensions/issue38600.dart:7:11: Error: Expected an identifier, but got 'try'.
+// pkg/front_end/testcases/extensions/issue38600.dart:7:11: Error: 'try' can't be used as an identifier because it's a keyword.
+// Try renaming this to be an identifier that isn't a keyword.
// extension try<T> on Class<T> {}
// ^^^
//
diff --git a/pkg/front_end/testcases/general/clone_function_type.dart.outline.expect b/pkg/front_end/testcases/general/clone_function_type.dart.outline.expect
index 9fd7126..def0418 100644
--- a/pkg/front_end/testcases/general/clone_function_type.dart.outline.expect
+++ b/pkg/front_end/testcases/general/clone_function_type.dart.outline.expect
@@ -3,26 +3,32 @@
// Problems in library:
//
// pkg/front_end/testcases/general/clone_function_type.dart:22:51: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Fm1<Z> extends Object with Am1<Function({int}), Z> {}
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:46:45: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Qm1<Z> = Object with Am1<Function({int}), Z>;
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:77:51: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Fm2<Z> extends Object with Am2<Function({int}), Z> {}
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:105:45: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Qm2<Z> = Object with Am2<Function({int}), Z>;
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:134:28: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// typedef TdF = Function({int});
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:190:34: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Ef1<X extends Function({int})> {
// ^
//
diff --git a/pkg/front_end/testcases/general/clone_function_type.dart.strong.expect b/pkg/front_end/testcases/general/clone_function_type.dart.strong.expect
index 9b9542f..a8b62fb 100644
--- a/pkg/front_end/testcases/general/clone_function_type.dart.strong.expect
+++ b/pkg/front_end/testcases/general/clone_function_type.dart.strong.expect
@@ -3,26 +3,32 @@
// Problems in library:
//
// pkg/front_end/testcases/general/clone_function_type.dart:22:51: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Fm1<Z> extends Object with Am1<Function({int}), Z> {}
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:46:45: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Qm1<Z> = Object with Am1<Function({int}), Z>;
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:77:51: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Fm2<Z> extends Object with Am2<Function({int}), Z> {}
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:105:45: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Qm2<Z> = Object with Am2<Function({int}), Z>;
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:134:28: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// typedef TdF = Function({int});
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:190:34: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Ef1<X extends Function({int})> {
// ^
//
diff --git a/pkg/front_end/testcases/general/clone_function_type.dart.strong.transformed.expect b/pkg/front_end/testcases/general/clone_function_type.dart.strong.transformed.expect
index 67d2466..7935b39 100644
--- a/pkg/front_end/testcases/general/clone_function_type.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/clone_function_type.dart.strong.transformed.expect
@@ -3,26 +3,32 @@
// Problems in library:
//
// pkg/front_end/testcases/general/clone_function_type.dart:22:51: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Fm1<Z> extends Object with Am1<Function({int}), Z> {}
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:46:45: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Qm1<Z> = Object with Am1<Function({int}), Z>;
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:77:51: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Fm2<Z> extends Object with Am2<Function({int}), Z> {}
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:105:45: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Qm2<Z> = Object with Am2<Function({int}), Z>;
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:134:28: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// typedef TdF = Function({int});
// ^
//
// pkg/front_end/testcases/general/clone_function_type.dart:190:34: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Ef1<X extends Function({int})> {
// ^
//
diff --git a/pkg/front_end/testcases/general/error_recovery/empty_await_for.dart.strong.expect b/pkg/front_end/testcases/general/error_recovery/empty_await_for.dart.strong.expect
index e8becc5..77d5da5 100644
--- a/pkg/front_end/testcases/general/error_recovery/empty_await_for.dart.strong.expect
+++ b/pkg/front_end/testcases/general/error_recovery/empty_await_for.dart.strong.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/general/error_recovery/empty_await_for.dart:2:14: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// await for () {}
// ^
//
diff --git a/pkg/front_end/testcases/general/error_recovery/empty_await_for.dart.strong.transformed.expect b/pkg/front_end/testcases/general/error_recovery/empty_await_for.dart.strong.transformed.expect
index c1b245b..b35db37 100644
--- a/pkg/front_end/testcases/general/error_recovery/empty_await_for.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/error_recovery/empty_await_for.dart.strong.transformed.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/general/error_recovery/empty_await_for.dart:2:14: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// await for () {}
// ^
//
diff --git a/pkg/front_end/testcases/general/error_recovery/empty_for.dart.strong.expect b/pkg/front_end/testcases/general/error_recovery/empty_for.dart.strong.expect
index 3bb7f2e..fa8d15f 100644
--- a/pkg/front_end/testcases/general/error_recovery/empty_for.dart.strong.expect
+++ b/pkg/front_end/testcases/general/error_recovery/empty_for.dart.strong.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/general/error_recovery/empty_for.dart:2:8: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// for () {}
// ^
//
diff --git a/pkg/front_end/testcases/general/error_recovery/empty_for.dart.strong.transformed.expect b/pkg/front_end/testcases/general/error_recovery/empty_for.dart.strong.transformed.expect
index c360df17..9344b10 100644
--- a/pkg/front_end/testcases/general/error_recovery/empty_for.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/error_recovery/empty_for.dart.strong.transformed.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/general/error_recovery/empty_for.dart:2:8: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// for () {}
// ^
//
diff --git a/pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart.outline.expect b/pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart.outline.expect
index 74ed3a8..6fb6069 100644
--- a/pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart.outline.expect
+++ b/pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart.outline.expect
@@ -15,6 +15,7 @@
// ^
//
// pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart:1:7: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// n<S e(
// ^...
//
diff --git a/pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart.strong.expect b/pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart.strong.expect
index 74ed3a8..6fb6069 100644
--- a/pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart.strong.expect
+++ b/pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart.strong.expect
@@ -15,6 +15,7 @@
// ^
//
// pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart:1:7: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// n<S e(
// ^...
//
diff --git a/pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart.strong.transformed.expect b/pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart.strong.transformed.expect
index 74ed3a8..6fb6069 100644
--- a/pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart.strong.transformed.expect
@@ -15,6 +15,7 @@
// ^
//
// pkg/front_end/testcases/general/error_recovery/issue_39024.crash_dart:1:7: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// n<S e(
// ^...
//
diff --git a/pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart.outline.expect b/pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart.outline.expect
index 961d9a1..5264a5a 100644
--- a/pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart.outline.expect
+++ b/pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart.outline.expect
@@ -20,6 +20,7 @@
// ^
//
// pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart:1:25: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// () async => a b < c $? >
// ^...
//
diff --git a/pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart.strong.expect b/pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart.strong.expect
index 4ad3dc2..a61de5e 100644
--- a/pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart.strong.expect
+++ b/pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart.strong.expect
@@ -20,6 +20,7 @@
// ^
//
// pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart:1:25: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// () async => a b < c $? >
// ^...
//
diff --git a/pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart.strong.transformed.expect b/pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart.strong.transformed.expect
index 4ad3dc2..a61de5e 100644
--- a/pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart.strong.transformed.expect
@@ -20,6 +20,7 @@
// ^
//
// pkg/front_end/testcases/general/error_recovery/issue_39202.crash_dart:1:25: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// () async => a b < c $? >
// ^...
//
diff --git a/pkg/front_end/testcases/general/for_in_without_declaration.dart.strong.expect b/pkg/front_end/testcases/general/for_in_without_declaration.dart.strong.expect
index 6b161b4..b1f7867 100644
--- a/pkg/front_end/testcases/general/for_in_without_declaration.dart.strong.expect
+++ b/pkg/front_end/testcases/general/for_in_without_declaration.dart.strong.expect
@@ -3,10 +3,12 @@
// Problems in library:
//
// pkg/front_end/testcases/general/for_in_without_declaration.dart:32:10: Error: Expected an identifier, but got 'super'.
+// Try inserting an identifier before 'super'.
// for (super.superInstanceField in []) {}
// ^^^^^
//
// pkg/front_end/testcases/general/for_in_without_declaration.dart:33:10: Error: Expected an identifier, but got 'super'.
+// Try inserting an identifier before 'super'.
// for (super.untypedSuperInstanceField in []) {}
// ^^^^^
//
diff --git a/pkg/front_end/testcases/general/for_in_without_declaration.dart.strong.transformed.expect b/pkg/front_end/testcases/general/for_in_without_declaration.dart.strong.transformed.expect
index 9e5e7ac..ea2e504 100644
--- a/pkg/front_end/testcases/general/for_in_without_declaration.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/for_in_without_declaration.dart.strong.transformed.expect
@@ -3,10 +3,12 @@
// Problems in library:
//
// pkg/front_end/testcases/general/for_in_without_declaration.dart:32:10: Error: Expected an identifier, but got 'super'.
+// Try inserting an identifier before 'super'.
// for (super.superInstanceField in []) {}
// ^^^^^
//
// pkg/front_end/testcases/general/for_in_without_declaration.dart:33:10: Error: Expected an identifier, but got 'super'.
+// Try inserting an identifier before 'super'.
// for (super.untypedSuperInstanceField in []) {}
// ^^^^^
//
diff --git a/pkg/front_end/testcases/general/function_type_default_value.dart.outline.expect b/pkg/front_end/testcases/general/function_type_default_value.dart.outline.expect
index 9d451cd..a4845bb 100644
--- a/pkg/front_end/testcases/general/function_type_default_value.dart.outline.expect
+++ b/pkg/front_end/testcases/general/function_type_default_value.dart.outline.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/general/function_type_default_value.dart:5:19: Error: Expected an identifier, but got ':'.
+// Try inserting an identifier before ':'.
// void Function({obj: Object}) x;
// ^
//
diff --git a/pkg/front_end/testcases/general/function_type_default_value.dart.strong.expect b/pkg/front_end/testcases/general/function_type_default_value.dart.strong.expect
index 4e7f6a6..37aef15 100644
--- a/pkg/front_end/testcases/general/function_type_default_value.dart.strong.expect
+++ b/pkg/front_end/testcases/general/function_type_default_value.dart.strong.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/general/function_type_default_value.dart:5:19: Error: Expected an identifier, but got ':'.
+// Try inserting an identifier before ':'.
// void Function({obj: Object}) x;
// ^
//
diff --git a/pkg/front_end/testcases/general/function_type_default_value.dart.strong.transformed.expect b/pkg/front_end/testcases/general/function_type_default_value.dart.strong.transformed.expect
index 4e7f6a6..37aef15 100644
--- a/pkg/front_end/testcases/general/function_type_default_value.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/function_type_default_value.dart.strong.transformed.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/general/function_type_default_value.dart:5:19: Error: Expected an identifier, but got ':'.
+// Try inserting an identifier before ':'.
// void Function({obj: Object}) x;
// ^
//
diff --git a/pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart.outline.expect b/pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart.outline.expect
index d2bc9fe..39fdd1f 100644
--- a/pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart.outline.expect
+++ b/pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart.outline.expect
@@ -7,10 +7,12 @@
// ^
//
// pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart:6:11: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// C.a(this);
// ^
//
// pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart:7:12: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// C.b(this.);
// ^
//
@@ -19,10 +21,12 @@
// ^
//
// pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart:8:11: Error: Expected an identifier, but got ','.
+// Try inserting an identifier before ','.
// C.c(this, p);
// ^
//
// pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart:9:12: Error: Expected an identifier, but got ','.
+// Try inserting an identifier before ','.
// C.d(this., p);
// ^
//
diff --git a/pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart.strong.expect b/pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart.strong.expect
index b147c01..ec23930 100644
--- a/pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart.strong.expect
+++ b/pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart.strong.expect
@@ -7,10 +7,12 @@
// ^
//
// pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart:6:11: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// C.a(this);
// ^
//
// pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart:7:12: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// C.b(this.);
// ^
//
@@ -19,10 +21,12 @@
// ^
//
// pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart:8:11: Error: Expected an identifier, but got ','.
+// Try inserting an identifier before ','.
// C.c(this, p);
// ^
//
// pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart:9:12: Error: Expected an identifier, but got ','.
+// Try inserting an identifier before ','.
// C.d(this., p);
// ^
//
diff --git a/pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart.strong.transformed.expect b/pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart.strong.transformed.expect
index b147c01..ec23930 100644
--- a/pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart.strong.transformed.expect
@@ -7,10 +7,12 @@
// ^
//
// pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart:6:11: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// C.a(this);
// ^
//
// pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart:7:12: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// C.b(this.);
// ^
//
@@ -19,10 +21,12 @@
// ^
//
// pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart:8:11: Error: Expected an identifier, but got ','.
+// Try inserting an identifier before ','.
// C.c(this, p);
// ^
//
// pkg/front_end/testcases/general/incomplete_field_formal_parameter.dart:9:12: Error: Expected an identifier, but got ','.
+// Try inserting an identifier before ','.
// C.d(this., p);
// ^
//
diff --git a/pkg/front_end/testcases/general/issue42610.dart.strong.expect b/pkg/front_end/testcases/general/issue42610.dart.strong.expect
index 77e5fc9..40fc5da 100644
--- a/pkg/front_end/testcases/general/issue42610.dart.strong.expect
+++ b/pkg/front_end/testcases/general/issue42610.dart.strong.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/general/issue42610.dart:6:4: Error: Expected an identifier, but got 'final'.
+// Try inserting an identifier before 'final'.
// #final;
// ^^^^^
//
@@ -11,6 +12,7 @@
// ^^^^^
//
// pkg/front_end/testcases/general/issue42610.dart:6:9: Error: Expected an identifier, but got ';'.
+// Try inserting an identifier before ';'.
// #final;
// ^
//
diff --git a/pkg/front_end/testcases/general/issue42610.dart.strong.transformed.expect b/pkg/front_end/testcases/general/issue42610.dart.strong.transformed.expect
index 77e5fc9..40fc5da 100644
--- a/pkg/front_end/testcases/general/issue42610.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/issue42610.dart.strong.transformed.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/general/issue42610.dart:6:4: Error: Expected an identifier, but got 'final'.
+// Try inserting an identifier before 'final'.
// #final;
// ^^^^^
//
@@ -11,6 +12,7 @@
// ^^^^^
//
// pkg/front_end/testcases/general/issue42610.dart:6:9: Error: Expected an identifier, but got ';'.
+// Try inserting an identifier before ';'.
// #final;
// ^
//
diff --git a/pkg/front_end/testcases/general/issue42997.dart.strong.expect b/pkg/front_end/testcases/general/issue42997.dart.strong.expect
index 2c07d53..40813a7 100644
--- a/pkg/front_end/testcases/general/issue42997.dart.strong.expect
+++ b/pkg/front_end/testcases/general/issue42997.dart.strong.expect
@@ -23,6 +23,7 @@
// ^^^^^^
//
// pkg/front_end/testcases/general/issue42997.dart:12:30: Error: Expected an identifier, but got ','.
+// Try inserting an identifier before ','.
// for (PropertyState<Object, Object>> state in _states) ;
// ^
//
diff --git a/pkg/front_end/testcases/general/issue42997.dart.strong.transformed.expect b/pkg/front_end/testcases/general/issue42997.dart.strong.transformed.expect
index 3706504..9151654 100644
--- a/pkg/front_end/testcases/general/issue42997.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/issue42997.dart.strong.transformed.expect
@@ -23,6 +23,7 @@
// ^^^^^^
//
// pkg/front_end/testcases/general/issue42997.dart:12:30: Error: Expected an identifier, but got ','.
+// Try inserting an identifier before ','.
// for (PropertyState<Object, Object>> state in _states) ;
// ^
//
diff --git a/pkg/front_end/testcases/general/operator_method_not_found.dart.strong.expect b/pkg/front_end/testcases/general/operator_method_not_found.dart.strong.expect
index 6c57b54..0f69d4e 100644
--- a/pkg/front_end/testcases/general/operator_method_not_found.dart.strong.expect
+++ b/pkg/front_end/testcases/general/operator_method_not_found.dart.strong.expect
@@ -15,18 +15,22 @@
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:37:9: Error: Expected an identifier, but got '>'.
+// Try inserting an identifier before '>'.
// print(>foo);
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:38:9: Error: Expected an identifier, but got '<='.
+// Try inserting an identifier before '<='.
// print(<=foo);
// ^^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:39:9: Error: Expected an identifier, but got '>='.
+// Try inserting an identifier before '>='.
// print(>=foo);
// ^^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:40:9: Error: Expected an identifier, but got '=='.
+// Try inserting an identifier before '=='.
// print(==foo);
// ^^
//
@@ -36,38 +40,47 @@
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:42:9: Error: Expected an identifier, but got '/'.
+// Try inserting an identifier before '/'.
// print(/foo);
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:43:9: Error: Expected an identifier, but got '~/'.
+// Try inserting an identifier before '~/'.
// print(~/foo);
// ^^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:44:9: Error: Expected an identifier, but got '*'.
+// Try inserting an identifier before '*'.
// print(*foo);
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:45:9: Error: Expected an identifier, but got '%'.
+// Try inserting an identifier before '%'.
// print(%foo);
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:46:9: Error: Expected an identifier, but got '|'.
+// Try inserting an identifier before '|'.
// print(|foo);
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:47:9: Error: Expected an identifier, but got '^'.
+// Try inserting an identifier before '^'.
// print(^foo);
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:48:9: Error: Expected an identifier, but got '&'.
+// Try inserting an identifier before '&'.
// print(&foo);
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:49:9: Error: Expected an identifier, but got '<<'.
+// Try inserting an identifier before '<<'.
// print(<<foo);
// ^^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:50:9: Error: Expected an identifier, but got '>>'.
+// Try inserting an identifier before '>>'.
// print(>>foo);
// ^^
//
diff --git a/pkg/front_end/testcases/general/operator_method_not_found.dart.strong.transformed.expect b/pkg/front_end/testcases/general/operator_method_not_found.dart.strong.transformed.expect
index 6c57b54..0f69d4e 100644
--- a/pkg/front_end/testcases/general/operator_method_not_found.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/operator_method_not_found.dart.strong.transformed.expect
@@ -15,18 +15,22 @@
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:37:9: Error: Expected an identifier, but got '>'.
+// Try inserting an identifier before '>'.
// print(>foo);
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:38:9: Error: Expected an identifier, but got '<='.
+// Try inserting an identifier before '<='.
// print(<=foo);
// ^^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:39:9: Error: Expected an identifier, but got '>='.
+// Try inserting an identifier before '>='.
// print(>=foo);
// ^^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:40:9: Error: Expected an identifier, but got '=='.
+// Try inserting an identifier before '=='.
// print(==foo);
// ^^
//
@@ -36,38 +40,47 @@
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:42:9: Error: Expected an identifier, but got '/'.
+// Try inserting an identifier before '/'.
// print(/foo);
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:43:9: Error: Expected an identifier, but got '~/'.
+// Try inserting an identifier before '~/'.
// print(~/foo);
// ^^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:44:9: Error: Expected an identifier, but got '*'.
+// Try inserting an identifier before '*'.
// print(*foo);
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:45:9: Error: Expected an identifier, but got '%'.
+// Try inserting an identifier before '%'.
// print(%foo);
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:46:9: Error: Expected an identifier, but got '|'.
+// Try inserting an identifier before '|'.
// print(|foo);
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:47:9: Error: Expected an identifier, but got '^'.
+// Try inserting an identifier before '^'.
// print(^foo);
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:48:9: Error: Expected an identifier, but got '&'.
+// Try inserting an identifier before '&'.
// print(&foo);
// ^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:49:9: Error: Expected an identifier, but got '<<'.
+// Try inserting an identifier before '<<'.
// print(<<foo);
// ^^
//
// pkg/front_end/testcases/general/operator_method_not_found.dart:50:9: Error: Expected an identifier, but got '>>'.
+// Try inserting an identifier before '>>'.
// print(>>foo);
// ^^
//
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart.weak.expect b/pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart.weak.expect
index 8b4a395..e189517 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart.weak.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart.weak.expect
@@ -3,26 +3,32 @@
// Problems in library:
//
// pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart:24:51: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Fm1<Z> extends Object with Am1<Function({int}), Z> {}
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart:48:45: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Qm1<Z> = Object with Am1<Function({int}), Z>;
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart:79:51: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Fm2<Z> extends Object with Am2<Function({int}), Z> {}
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart:107:45: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Qm2<Z> = Object with Am2<Function({int}), Z>;
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart:136:28: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// typedef TdF = Function({int});
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart:192:34: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Ef1<X extends Function({int})> {
// ^
//
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart.weak.transformed.expect b/pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart.weak.transformed.expect
index 511e518..02dce8f 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart.weak.transformed.expect
@@ -3,26 +3,32 @@
// Problems in library:
//
// pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart:24:51: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Fm1<Z> extends Object with Am1<Function({int}), Z> {}
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart:48:45: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Qm1<Z> = Object with Am1<Function({int}), Z>;
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart:79:51: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Fm2<Z> extends Object with Am2<Function({int}), Z> {}
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart:107:45: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Qm2<Z> = Object with Am2<Function({int}), Z>;
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart:136:28: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// typedef TdF = Function({int});
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/clone_function_type.dart:192:34: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class Ef1<X extends Function({int})> {
// ^
//
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/for_in_without_declaration.dart.weak.expect b/pkg/front_end/testcases/general_nnbd_opt_out/for_in_without_declaration.dart.weak.expect
index 6320f0f..158f177 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/for_in_without_declaration.dart.weak.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/for_in_without_declaration.dart.weak.expect
@@ -3,10 +3,12 @@
// Problems in library:
//
// pkg/front_end/testcases/general_nnbd_opt_out/for_in_without_declaration.dart:34:10: Error: Expected an identifier, but got 'super'.
+// Try inserting an identifier before 'super'.
// for (super.superInstanceField in []) {}
// ^^^^^
//
// pkg/front_end/testcases/general_nnbd_opt_out/for_in_without_declaration.dart:35:10: Error: Expected an identifier, but got 'super'.
+// Try inserting an identifier before 'super'.
// for (super.untypedSuperInstanceField in []) {}
// ^^^^^
//
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/for_in_without_declaration.dart.weak.transformed.expect b/pkg/front_end/testcases/general_nnbd_opt_out/for_in_without_declaration.dart.weak.transformed.expect
index ac8efc4..7eb73d5 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/for_in_without_declaration.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/for_in_without_declaration.dart.weak.transformed.expect
@@ -3,10 +3,12 @@
// Problems in library:
//
// pkg/front_end/testcases/general_nnbd_opt_out/for_in_without_declaration.dart:34:10: Error: Expected an identifier, but got 'super'.
+// Try inserting an identifier before 'super'.
// for (super.superInstanceField in []) {}
// ^^^^^
//
// pkg/front_end/testcases/general_nnbd_opt_out/for_in_without_declaration.dart:35:10: Error: Expected an identifier, but got 'super'.
+// Try inserting an identifier before 'super'.
// for (super.untypedSuperInstanceField in []) {}
// ^^^^^
//
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/function_type_default_value.dart.weak.expect b/pkg/front_end/testcases/general_nnbd_opt_out/function_type_default_value.dart.weak.expect
index c6f2e39..67a7869 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/function_type_default_value.dart.weak.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/function_type_default_value.dart.weak.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/general_nnbd_opt_out/function_type_default_value.dart:7:19: Error: Expected an identifier, but got ':'.
+// Try inserting an identifier before ':'.
// void Function({obj: Object}) x;
// ^
//
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/function_type_default_value.dart.weak.transformed.expect b/pkg/front_end/testcases/general_nnbd_opt_out/function_type_default_value.dart.weak.transformed.expect
index c6f2e39..67a7869 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/function_type_default_value.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/function_type_default_value.dart.weak.transformed.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/general_nnbd_opt_out/function_type_default_value.dart:7:19: Error: Expected an identifier, but got ':'.
+// Try inserting an identifier before ':'.
// void Function({obj: Object}) x;
// ^
//
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart.weak.expect b/pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart.weak.expect
index 120c7e3..4f7c820 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart.weak.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart.weak.expect
@@ -7,10 +7,12 @@
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart:8:11: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// C.a(this);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart:9:12: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// C.b(this.);
// ^
//
@@ -19,10 +21,12 @@
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart:10:11: Error: Expected an identifier, but got ','.
+// Try inserting an identifier before ','.
// C.c(this, p);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart:11:12: Error: Expected an identifier, but got ','.
+// Try inserting an identifier before ','.
// C.d(this., p);
// ^
//
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart.weak.transformed.expect b/pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart.weak.transformed.expect
index 120c7e3..4f7c820 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart.weak.transformed.expect
@@ -7,10 +7,12 @@
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart:8:11: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// C.a(this);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart:9:12: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// C.b(this.);
// ^
//
@@ -19,10 +21,12 @@
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart:10:11: Error: Expected an identifier, but got ','.
+// Try inserting an identifier before ','.
// C.c(this, p);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/incomplete_field_formal_parameter.dart:11:12: Error: Expected an identifier, but got ','.
+// Try inserting an identifier before ','.
// C.d(this., p);
// ^
//
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart.weak.expect b/pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart.weak.expect
index 9099bb0..6717947 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart.weak.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart.weak.expect
@@ -15,18 +15,22 @@
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:39:9: Error: Expected an identifier, but got '>'.
+// Try inserting an identifier before '>'.
// print(>foo);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:40:9: Error: Expected an identifier, but got '<='.
+// Try inserting an identifier before '<='.
// print(<=foo);
// ^^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:41:9: Error: Expected an identifier, but got '>='.
+// Try inserting an identifier before '>='.
// print(>=foo);
// ^^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:42:9: Error: Expected an identifier, but got '=='.
+// Try inserting an identifier before '=='.
// print(==foo);
// ^^
//
@@ -36,38 +40,47 @@
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:44:9: Error: Expected an identifier, but got '/'.
+// Try inserting an identifier before '/'.
// print(/foo);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:45:9: Error: Expected an identifier, but got '~/'.
+// Try inserting an identifier before '~/'.
// print(~/foo);
// ^^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:46:9: Error: Expected an identifier, but got '*'.
+// Try inserting an identifier before '*'.
// print(*foo);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:47:9: Error: Expected an identifier, but got '%'.
+// Try inserting an identifier before '%'.
// print(%foo);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:48:9: Error: Expected an identifier, but got '|'.
+// Try inserting an identifier before '|'.
// print(|foo);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:49:9: Error: Expected an identifier, but got '^'.
+// Try inserting an identifier before '^'.
// print(^foo);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:50:9: Error: Expected an identifier, but got '&'.
+// Try inserting an identifier before '&'.
// print(&foo);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:51:9: Error: Expected an identifier, but got '<<'.
+// Try inserting an identifier before '<<'.
// print(<<foo);
// ^^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:52:9: Error: Expected an identifier, but got '>>'.
+// Try inserting an identifier before '>>'.
// print(>>foo);
// ^^
//
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart.weak.transformed.expect b/pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart.weak.transformed.expect
index 9099bb0..6717947 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart.weak.transformed.expect
@@ -15,18 +15,22 @@
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:39:9: Error: Expected an identifier, but got '>'.
+// Try inserting an identifier before '>'.
// print(>foo);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:40:9: Error: Expected an identifier, but got '<='.
+// Try inserting an identifier before '<='.
// print(<=foo);
// ^^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:41:9: Error: Expected an identifier, but got '>='.
+// Try inserting an identifier before '>='.
// print(>=foo);
// ^^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:42:9: Error: Expected an identifier, but got '=='.
+// Try inserting an identifier before '=='.
// print(==foo);
// ^^
//
@@ -36,38 +40,47 @@
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:44:9: Error: Expected an identifier, but got '/'.
+// Try inserting an identifier before '/'.
// print(/foo);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:45:9: Error: Expected an identifier, but got '~/'.
+// Try inserting an identifier before '~/'.
// print(~/foo);
// ^^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:46:9: Error: Expected an identifier, but got '*'.
+// Try inserting an identifier before '*'.
// print(*foo);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:47:9: Error: Expected an identifier, but got '%'.
+// Try inserting an identifier before '%'.
// print(%foo);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:48:9: Error: Expected an identifier, but got '|'.
+// Try inserting an identifier before '|'.
// print(|foo);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:49:9: Error: Expected an identifier, but got '^'.
+// Try inserting an identifier before '^'.
// print(^foo);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:50:9: Error: Expected an identifier, but got '&'.
+// Try inserting an identifier before '&'.
// print(&foo);
// ^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:51:9: Error: Expected an identifier, but got '<<'.
+// Try inserting an identifier before '<<'.
// print(<<foo);
// ^^
//
// pkg/front_end/testcases/general_nnbd_opt_out/operator_method_not_found.dart:52:9: Error: Expected an identifier, but got '>>'.
+// Try inserting an identifier before '>>'.
// print(>>foo);
// ^^
//
diff --git a/pkg/front_end/testcases/inference/async_await.dart.outline.expect b/pkg/front_end/testcases/inference/async_await.dart.outline.expect
index 5c7c774..f148d78 100644
--- a/pkg/front_end/testcases/inference/async_await.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/async_await.dart.outline.expect
@@ -22,7 +22,7 @@
abstract member-signature method catchError(core::Function* onError, {(core::Object*) →* core::bool* test}) → asy::Future<core::int*>*; -> asy::Future::catchError
abstract member-signature method whenComplete(() →* FutureOr<void>* action) → asy::Future<core::int*>*; -> asy::Future::whenComplete
abstract member-signature method asStream() → asy::Stream<core::int*>*; -> asy::Future::asStream
- abstract member-signature method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<core::int*>onTimeout}) → asy::Future<core::int*>*; -> asy::Future::timeout
+ abstract member-signature method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<core::int*>* onTimeout}) → asy::Future<core::int*>*; -> asy::Future::timeout
}
static method test() → void async
;
diff --git a/pkg/front_end/testcases/inference/async_await.dart.strong.expect b/pkg/front_end/testcases/inference/async_await.dart.strong.expect
index b99c76b..3505342 100644
--- a/pkg/front_end/testcases/inference/async_await.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/async_await.dart.strong.expect
@@ -23,7 +23,7 @@
abstract member-signature method catchError(core::Function* onError, {(core::Object*) →* core::bool* test = #C1}) → asy::Future<core::int*>*; -> asy::Future::catchError
abstract member-signature method whenComplete(() →* FutureOr<void>* action) → asy::Future<core::int*>*; -> asy::Future::whenComplete
abstract member-signature method asStream() → asy::Stream<core::int*>*; -> asy::Future::asStream
- abstract member-signature method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<core::int*>onTimeout = #C1}) → asy::Future<core::int*>*; -> asy::Future::timeout
+ abstract member-signature method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<core::int*>* onTimeout = #C1}) → asy::Future<core::int*>*; -> asy::Future::timeout
}
static method test() → void async {
core::int* x0;
diff --git a/pkg/front_end/testcases/inference/async_await.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/async_await.dart.strong.transformed.expect
index d764e00..0903294 100644
--- a/pkg/front_end/testcases/inference/async_await.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/async_await.dart.strong.transformed.expect
@@ -24,7 +24,7 @@
abstract member-signature method catchError(core::Function* onError, {(core::Object*) →* core::bool* test = #C1}) → asy::Future<core::int*>*; -> asy::Future::catchError
abstract member-signature method whenComplete(() →* FutureOr<void>* action) → asy::Future<core::int*>*; -> asy::Future::whenComplete
abstract member-signature method asStream() → asy::Stream<core::int*>*; -> asy::Future::asStream
- abstract member-signature method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<core::int*>onTimeout = #C1}) → asy::Future<core::int*>*; -> asy::Future::timeout
+ abstract member-signature method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<core::int*>* onTimeout = #C1}) → asy::Future<core::int*>*; -> asy::Future::timeout
}
static method test() → void /* originally async */ {
final asy::_AsyncAwaitCompleter<dynamic>* :async_completer = new asy::_AsyncAwaitCompleter::•<dynamic>();
diff --git a/pkg/front_end/testcases/inference/future_then.dart.outline.expect b/pkg/front_end/testcases/inference/future_then.dart.outline.expect
index c766d86..9f214cc 100644
--- a/pkg/front_end/testcases/inference/future_then.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void
diff --git a/pkg/front_end/testcases/inference/future_then.dart.strong.expect b/pkg/front_end/testcases/inference/future_then.dart.strong.expect
index a9e40184..2d476b4 100644
--- a/pkg/front_end/testcases/inference/future_then.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then.dart.strong.transformed.expect
index 99e6514..15b315a 100644
--- a/pkg/front_end/testcases/inference/future_then.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then.dart.strong.transformed.expect
@@ -30,7 +30,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_2.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_2.dart.outline.expect
index c766d86..9f214cc 100644
--- a/pkg/front_end/testcases/inference/future_then_2.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_2.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void
diff --git a/pkg/front_end/testcases/inference/future_then_2.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_2.dart.strong.expect
index 7fb39f6..9755c88 100644
--- a/pkg/front_end/testcases/inference/future_then_2.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_2.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_2.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_2.dart.strong.transformed.expect
index 1be1c3f..e5e7002 100644
--- a/pkg/front_end/testcases/inference/future_then_2.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_2.dart.strong.transformed.expect
@@ -30,7 +30,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_3.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_3.dart.outline.expect
index c766d86..9f214cc 100644
--- a/pkg/front_end/testcases/inference/future_then_3.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_3.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void
diff --git a/pkg/front_end/testcases/inference/future_then_3.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_3.dart.strong.expect
index b39606f..79fbdd6 100644
--- a/pkg/front_end/testcases/inference/future_then_3.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_3.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_3.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_3.dart.strong.transformed.expect
index e7a676e..9e2db60 100644
--- a/pkg/front_end/testcases/inference/future_then_3.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_3.dart.strong.transformed.expect
@@ -30,7 +30,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_4.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_4.dart.outline.expect
index c766d86..9f214cc 100644
--- a/pkg/front_end/testcases/inference/future_then_4.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_4.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void
diff --git a/pkg/front_end/testcases/inference/future_then_4.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_4.dart.strong.expect
index eb2b35f..090effe 100644
--- a/pkg/front_end/testcases/inference/future_then_4.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_4.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_4.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_4.dart.strong.transformed.expect
index ce704e2..c37addd 100644
--- a/pkg/front_end/testcases/inference/future_then_4.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_4.dart.strong.transformed.expect
@@ -30,7 +30,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_5.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_5.dart.outline.expect
index c766d86..9f214cc 100644
--- a/pkg/front_end/testcases/inference/future_then_5.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_5.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void
diff --git a/pkg/front_end/testcases/inference/future_then_5.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_5.dart.strong.expect
index c141fb2..9988e76 100644
--- a/pkg/front_end/testcases/inference/future_then_5.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_5.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_5.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_5.dart.strong.transformed.expect
index 50fec58..27c8361 100644
--- a/pkg/front_end/testcases/inference/future_then_5.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_5.dart.strong.transformed.expect
@@ -30,7 +30,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_6.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_6.dart.outline.expect
index c766d86..9f214cc 100644
--- a/pkg/front_end/testcases/inference/future_then_6.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_6.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void
diff --git a/pkg/front_end/testcases/inference/future_then_6.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_6.dart.strong.expect
index baec351..7df4804 100644
--- a/pkg/front_end/testcases/inference/future_then_6.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_6.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_6.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_6.dart.strong.transformed.expect
index 6091b44..25b8d87 100644
--- a/pkg/front_end/testcases/inference/future_then_6.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_6.dart.strong.transformed.expect
@@ -30,7 +30,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_conditional.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_conditional.dart.outline.expect
index c766d86..9f214cc 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void
diff --git a/pkg/front_end/testcases/inference/future_then_conditional.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_conditional.dart.strong.expect
index f94dd6a..7bbdb21 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_conditional.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_conditional.dart.strong.transformed.expect
index 10ecbed..9be32a1 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional.dart.strong.transformed.expect
@@ -30,7 +30,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_2.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_conditional_2.dart.outline.expect
index c766d86..9f214cc 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_2.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_2.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_2.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_conditional_2.dart.strong.expect
index 771b278..ac6c2b0 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_2.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_2.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_2.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_conditional_2.dart.strong.transformed.expect
index f4bb5a9..4067e3e 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_2.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_2.dart.strong.transformed.expect
@@ -30,7 +30,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_3.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_conditional_3.dart.outline.expect
index c766d86..9f214cc 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_3.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_3.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_3.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_conditional_3.dart.strong.expect
index c23a047..cf29dae 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_3.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_3.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_3.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_conditional_3.dart.strong.transformed.expect
index eef7092..63fe450 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_3.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_3.dart.strong.transformed.expect
@@ -30,7 +30,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_4.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_conditional_4.dart.outline.expect
index c766d86..9f214cc 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_4.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_4.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_4.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_conditional_4.dart.strong.expect
index 36ad941..a3755b3 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_4.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_4.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_4.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_conditional_4.dart.strong.transformed.expect
index e8aa435..a51edd8 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_4.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_4.dart.strong.transformed.expect
@@ -30,7 +30,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_5.dart b/pkg/front_end/testcases/inference/future_then_conditional_5.dart
index e44607b..413f5b1 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_5.dart
+++ b/pkg/front_end/testcases/inference/future_then_conditional_5.dart
@@ -20,17 +20,17 @@
/*@ returnType=Future<int*>* */ (/*@ type=bool* */ x) async =>
x ? 2 : await new MyFuture<int>.value(3));
Future<int> t2 = f. /*@ typeArgs=int* */ /*@target=Future.then*/ then(
- /*@returnType=FutureOr<int*>*/ (/*@ type=bool* */ x) async {
+ /*@returnType=FutureOr<int*>**/ (/*@ type=bool* */ x) async {
return /*info:DOWN_CAST_COMPOSITE*/ await x
? 2
: new MyFuture<int>.value(3);
});
Future<int> t5 = f. /*@ typeArgs=int* */ /*@target=Future.then*/ then(
/*info:INFERRED_TYPE_CLOSURE,error:INVALID_CAST_FUNCTION_EXPR*/
- /*@ returnType=FutureOr<int*> */ (/*@ type=bool* */ x) =>
+ /*@returnType=FutureOr<int*>**/ (/*@ type=bool* */ x) =>
x ? 2 : new MyFuture<int>.value(3));
Future<int> t6 = f. /*@ typeArgs=int* */ /*@target=Future.then*/ then(
- /*@ returnType=FutureOr<int*> */ (/*@ type=bool* */ x) {
+ /*@returnType=FutureOr<int*>**/ (/*@ type=bool* */ x) {
return /*info:DOWN_CAST_COMPOSITE*/ x ? 2 : new MyFuture<int>.value(3);
});
}
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_5.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_conditional_5.dart.outline.expect
index c766d86..9f214cc 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_5.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_5.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_5.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_conditional_5.dart.strong.expect
index 61c1617..52b58db 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_5.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_5.dart.strong.expect
@@ -29,18 +29,18 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
asy::Future<core::bool*>* f;
asy::Future<core::int*>* t1 = f.{asy::Future::then}<core::int*>((core::bool* x) → asy::Future<core::int*>* async => x ?{core::int*} 2 : await new self::MyFuture::value<core::int*>(3));
- asy::Future<core::int*>* t2 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*> async {
+ asy::Future<core::int*>* t2 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*>* async {
return (await x ?{core::Object*} 2 : new self::MyFuture::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>*;
});
- asy::Future<core::int*>* t5 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*> => (x ?{core::Object*} 2 : new self::MyFuture::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>);
- asy::Future<core::int*>* t6 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*> {
- return (x ?{core::Object*} 2 : new self::MyFuture::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>;
+ asy::Future<core::int*>* t5 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*>* => (x ?{core::Object*} 2 : new self::MyFuture::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>*);
+ asy::Future<core::int*>* t6 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*>* {
+ return (x ?{core::Object*} 2 : new self::MyFuture::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>*;
});
}
static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_5.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_conditional_5.dart.strong.transformed.expect
index 7972bbb..584f94a 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_5.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_5.dart.strong.transformed.expect
@@ -30,7 +30,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
@@ -71,7 +71,7 @@
:async_completer.{asy::_AsyncAwaitCompleter::start}(:async_op);
return :async_completer.{asy::Completer::future};
});
- asy::Future<core::int*>* t2 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*> /* originally async */ {
+ asy::Future<core::int*>* t2 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*>* /* originally async */ {
final asy::_AsyncAwaitCompleter<core::int*>* :async_completer = new asy::_AsyncAwaitCompleter::•<core::int*>();
FutureOr<core::int*>* :return_value;
dynamic :async_stack_trace;
@@ -100,9 +100,9 @@
:async_completer.{asy::_AsyncAwaitCompleter::start}(:async_op);
return :async_completer.{asy::Completer::future};
});
- asy::Future<core::int*>* t5 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*> => (x ?{core::Object*} 2 : new self::MyFuture::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>);
- asy::Future<core::int*>* t6 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*> {
- return (x ?{core::Object*} 2 : new self::MyFuture::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>;
+ asy::Future<core::int*>* t5 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*>* => (x ?{core::Object*} 2 : new self::MyFuture::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>*);
+ asy::Future<core::int*>* t6 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*>* {
+ return (x ?{core::Object*} 2 : new self::MyFuture::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>*;
});
}
static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_6.dart b/pkg/front_end/testcases/inference/future_then_conditional_6.dart
index 4a0cc0e..d502d9b 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_6.dart
+++ b/pkg/front_end/testcases/inference/future_then_conditional_6.dart
@@ -20,15 +20,15 @@
/*@ returnType=Future<int*>* */ (/*@ type=bool* */ x) async =>
x ? 2 : await new Future<int>.value(3));
Future<int> t2 = f. /*@ typeArgs=int* */ /*@target=Future.then*/ then(
- /*@returnType=FutureOr<int*>*/ (/*@ type=bool* */ x) async {
+ /*@returnType=FutureOr<int*>**/ (/*@ type=bool* */ x) async {
return /*info:DOWN_CAST_COMPOSITE*/ await x ? 2 : new Future<int>.value(3);
});
Future<int> t5 = f. /*@ typeArgs=int* */ /*@target=Future.then*/ then(
/*info:INFERRED_TYPE_CLOSURE,error:INVALID_CAST_FUNCTION_EXPR*/
- /*@ returnType=FutureOr<int*> */ (/*@ type=bool* */ x) =>
+ /*@returnType=FutureOr<int*>**/ (/*@ type=bool* */ x) =>
x ? 2 : new Future<int>.value(3));
Future<int> t6 = f. /*@ typeArgs=int* */ /*@target=Future.then*/ then(
- /*@ returnType=FutureOr<int*> */ (/*@ type=bool* */ x) {
+ /*@returnType=FutureOr<int*>**/ (/*@ type=bool* */ x) {
return /*info:DOWN_CAST_COMPOSITE*/ x ? 2 : new Future<int>.value(3);
});
}
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_6.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_conditional_6.dart.outline.expect
index c766d86..9f214cc 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_6.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_6.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_6.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_conditional_6.dart.strong.expect
index db5bebc..3603d46 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_6.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_6.dart.strong.expect
@@ -29,18 +29,18 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
asy::Future<core::bool*>* f;
asy::Future<core::int*>* t1 = f.{asy::Future::then}<core::int*>((core::bool* x) → asy::Future<core::int*>* async => x ?{core::int*} 2 : await asy::Future::value<core::int*>(3));
- asy::Future<core::int*>* t2 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*> async {
+ asy::Future<core::int*>* t2 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*>* async {
return (await x ?{core::Object*} 2 : asy::Future::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>*;
});
- asy::Future<core::int*>* t5 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*> => (x ?{core::Object*} 2 : asy::Future::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>);
- asy::Future<core::int*>* t6 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*> {
- return (x ?{core::Object*} 2 : asy::Future::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>;
+ asy::Future<core::int*>* t5 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*>* => (x ?{core::Object*} 2 : asy::Future::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>*);
+ asy::Future<core::int*>* t6 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*>* {
+ return (x ?{core::Object*} 2 : asy::Future::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>*;
});
}
static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/inference/future_then_conditional_6.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_conditional_6.dart.strong.transformed.expect
index ef8cb30..e7d7fe7 100644
--- a/pkg/front_end/testcases/inference/future_then_conditional_6.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_conditional_6.dart.strong.transformed.expect
@@ -30,7 +30,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
@@ -71,7 +71,7 @@
:async_completer.{asy::_AsyncAwaitCompleter::start}(:async_op);
return :async_completer.{asy::Completer::future};
});
- asy::Future<core::int*>* t2 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*> /* originally async */ {
+ asy::Future<core::int*>* t2 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*>* /* originally async */ {
final asy::_AsyncAwaitCompleter<core::int*>* :async_completer = new asy::_AsyncAwaitCompleter::•<core::int*>();
FutureOr<core::int*>* :return_value;
dynamic :async_stack_trace;
@@ -100,9 +100,9 @@
:async_completer.{asy::_AsyncAwaitCompleter::start}(:async_op);
return :async_completer.{asy::Completer::future};
});
- asy::Future<core::int*>* t5 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*> => (x ?{core::Object*} 2 : asy::Future::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>);
- asy::Future<core::int*>* t6 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*> {
- return (x ?{core::Object*} 2 : asy::Future::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>;
+ asy::Future<core::int*>* t5 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*>* => (x ?{core::Object*} 2 : asy::Future::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>*);
+ asy::Future<core::int*>* t6 = f.{asy::Future::then}<core::int*>((core::bool* x) → FutureOr<core::int*>* {
+ return (x ?{core::Object*} 2 : asy::Future::value<core::int*>(3)) as{TypeError} FutureOr<core::int*>*;
});
}
static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/inference/future_then_explicit_future.dart b/pkg/front_end/testcases/inference/future_then_explicit_future.dart
index c1d7db6..c14e152 100644
--- a/pkg/front_end/testcases/inference/future_then_explicit_future.dart
+++ b/pkg/front_end/testcases/inference/future_then_explicit_future.dart
@@ -12,7 +12,7 @@
var /*@type=Future<Future<List<int*>*>*>**/ x = f. /*@target=Future.then*/ then<
Future<List<int>>>(
/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/
- /*@returnType=FutureOr<Future<List<int*>*>*>*/ (/*@type=int**/ x) => /*@typeArgs=dynamic*/ []);
+ /*@returnType=FutureOr<Future<List<int*>*>*>**/ (/*@type=int**/ x) => /*@typeArgs=dynamic*/ []);
Future<List<int>> y = x;
}
diff --git a/pkg/front_end/testcases/inference/future_then_explicit_future.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_explicit_future.dart.strong.expect
index 8cb973a..cf41d05 100644
--- a/pkg/front_end/testcases/inference/future_then_explicit_future.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_explicit_future.dart.strong.expect
@@ -2,11 +2,11 @@
//
// Problems in library:
//
-// pkg/front_end/testcases/inference/future_then_explicit_future.dart:15:98: Error: A value of type 'List<dynamic>' can't be assigned to a variable of type 'FutureOr<Future<List<int>>>'.
+// pkg/front_end/testcases/inference/future_then_explicit_future.dart:15:99: Error: A value of type 'List<dynamic>' can't be assigned to a variable of type 'FutureOr<Future<List<int>>>'.
// - 'List' is from 'dart:core'.
// - 'Future' is from 'dart:async'.
-// /*@returnType=FutureOr<Future<List<int*>*>*>*/ (/*@type=int**/ x) => /*@typeArgs=dynamic*/ []);
-// ^
+// /*@returnType=FutureOr<Future<List<int*>*>*>**/ (/*@type=int**/ x) => /*@typeArgs=dynamic*/ []);
+// ^
//
// pkg/front_end/testcases/inference/future_then_explicit_future.dart:16:25: Error: A value of type 'Future<Future<List<int>>>' can't be assigned to a variable of type 'Future<List<int>>'.
// - 'Future' is from 'dart:async'.
@@ -22,11 +22,11 @@
static method m1() → dynamic {
asy::Future<core::int*>* f;
- asy::Future<asy::Future<core::List<core::int*>*>*>* x = f.{asy::Future::then}<asy::Future<core::List<core::int*>*>*>((core::int* x) → FutureOr<asy::Future<core::List<core::int*>*>*> => let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/inference/future_then_explicit_future.dart:15:98: Error: A value of type 'List<dynamic>' can't be assigned to a variable of type 'FutureOr<Future<List<int>>>'.
+ asy::Future<asy::Future<core::List<core::int*>*>*>* x = f.{asy::Future::then}<asy::Future<core::List<core::int*>*>*>((core::int* x) → FutureOr<asy::Future<core::List<core::int*>*>*>* => let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/inference/future_then_explicit_future.dart:15:99: Error: A value of type 'List<dynamic>' can't be assigned to a variable of type 'FutureOr<Future<List<int>>>'.
- 'List' is from 'dart:core'.
- 'Future' is from 'dart:async'.
- /*@returnType=FutureOr<Future<List<int*>*>*>*/ (/*@type=int**/ x) => /*@typeArgs=dynamic*/ []);
- ^" in <dynamic>[] as{TypeError} FutureOr<asy::Future<core::List<core::int*>*>*>);
+ /*@returnType=FutureOr<Future<List<int*>*>*>**/ (/*@type=int**/ x) => /*@typeArgs=dynamic*/ []);
+ ^" in <dynamic>[] as{TypeError} FutureOr<asy::Future<core::List<core::int*>*>*>*);
asy::Future<core::List<core::int*>*>* y = let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/inference/future_then_explicit_future.dart:16:25: Error: A value of type 'Future<Future<List<int>>>' can't be assigned to a variable of type 'Future<List<int>>'.
- 'Future' is from 'dart:async'.
- 'List' is from 'dart:core'.
diff --git a/pkg/front_end/testcases/inference/future_then_explicit_future.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_explicit_future.dart.strong.transformed.expect
index 8cb973a..cf41d05 100644
--- a/pkg/front_end/testcases/inference/future_then_explicit_future.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_explicit_future.dart.strong.transformed.expect
@@ -2,11 +2,11 @@
//
// Problems in library:
//
-// pkg/front_end/testcases/inference/future_then_explicit_future.dart:15:98: Error: A value of type 'List<dynamic>' can't be assigned to a variable of type 'FutureOr<Future<List<int>>>'.
+// pkg/front_end/testcases/inference/future_then_explicit_future.dart:15:99: Error: A value of type 'List<dynamic>' can't be assigned to a variable of type 'FutureOr<Future<List<int>>>'.
// - 'List' is from 'dart:core'.
// - 'Future' is from 'dart:async'.
-// /*@returnType=FutureOr<Future<List<int*>*>*>*/ (/*@type=int**/ x) => /*@typeArgs=dynamic*/ []);
-// ^
+// /*@returnType=FutureOr<Future<List<int*>*>*>**/ (/*@type=int**/ x) => /*@typeArgs=dynamic*/ []);
+// ^
//
// pkg/front_end/testcases/inference/future_then_explicit_future.dart:16:25: Error: A value of type 'Future<Future<List<int>>>' can't be assigned to a variable of type 'Future<List<int>>'.
// - 'Future' is from 'dart:async'.
@@ -22,11 +22,11 @@
static method m1() → dynamic {
asy::Future<core::int*>* f;
- asy::Future<asy::Future<core::List<core::int*>*>*>* x = f.{asy::Future::then}<asy::Future<core::List<core::int*>*>*>((core::int* x) → FutureOr<asy::Future<core::List<core::int*>*>*> => let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/inference/future_then_explicit_future.dart:15:98: Error: A value of type 'List<dynamic>' can't be assigned to a variable of type 'FutureOr<Future<List<int>>>'.
+ asy::Future<asy::Future<core::List<core::int*>*>*>* x = f.{asy::Future::then}<asy::Future<core::List<core::int*>*>*>((core::int* x) → FutureOr<asy::Future<core::List<core::int*>*>*>* => let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/inference/future_then_explicit_future.dart:15:99: Error: A value of type 'List<dynamic>' can't be assigned to a variable of type 'FutureOr<Future<List<int>>>'.
- 'List' is from 'dart:core'.
- 'Future' is from 'dart:async'.
- /*@returnType=FutureOr<Future<List<int*>*>*>*/ (/*@type=int**/ x) => /*@typeArgs=dynamic*/ []);
- ^" in <dynamic>[] as{TypeError} FutureOr<asy::Future<core::List<core::int*>*>*>);
+ /*@returnType=FutureOr<Future<List<int*>*>*>**/ (/*@type=int**/ x) => /*@typeArgs=dynamic*/ []);
+ ^" in <dynamic>[] as{TypeError} FutureOr<asy::Future<core::List<core::int*>*>*>*);
asy::Future<core::List<core::int*>*>* y = let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/inference/future_then_explicit_future.dart:16:25: Error: A value of type 'Future<Future<List<int>>>' can't be assigned to a variable of type 'Future<List<int>>'.
- 'Future' is from 'dart:async'.
- 'List' is from 'dart:core'.
diff --git a/pkg/front_end/testcases/inference/future_then_ifNull.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_ifNull.dart.outline.expect
index c766d86..9f214cc 100644
--- a/pkg/front_end/testcases/inference/future_then_ifNull.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_ifNull.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void
diff --git a/pkg/front_end/testcases/inference/future_then_ifNull.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_ifNull.dart.strong.expect
index 1d3a7b5..4771d6d 100644
--- a/pkg/front_end/testcases/inference/future_then_ifNull.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_ifNull.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_ifNull.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_ifNull.dart.strong.transformed.expect
index f4e1ed0..debc669 100644
--- a/pkg/front_end/testcases/inference/future_then_ifNull.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_ifNull.dart.strong.transformed.expect
@@ -30,7 +30,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_upwards.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_upwards.dart.outline.expect
index 20a111b..52a1a8c 100644
--- a/pkg/front_end/testcases/inference/future_then_upwards.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_upwards.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method main() → void
diff --git a/pkg/front_end/testcases/inference/future_then_upwards.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_upwards.dart.strong.expect
index 3cc4af5..ee70fad 100644
--- a/pkg/front_end/testcases/inference/future_then_upwards.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_upwards.dart.strong.expect
@@ -38,7 +38,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method main() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_upwards.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_upwards.dart.strong.transformed.expect
index c2a6d0c..31e558a 100644
--- a/pkg/front_end/testcases/inference/future_then_upwards.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_upwards.dart.strong.transformed.expect
@@ -38,7 +38,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method main() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_upwards_2.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_upwards_2.dart.outline.expect
index 20a111b..52a1a8c 100644
--- a/pkg/front_end/testcases/inference/future_then_upwards_2.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_upwards_2.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method main() → void
diff --git a/pkg/front_end/testcases/inference/future_then_upwards_2.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_upwards_2.dart.strong.expect
index 51e731e..48b7a9a 100644
--- a/pkg/front_end/testcases/inference/future_then_upwards_2.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_upwards_2.dart.strong.expect
@@ -37,7 +37,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method main() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_upwards_2.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_upwards_2.dart.strong.transformed.expect
index 2cc8750..d6e485a 100644
--- a/pkg/front_end/testcases/inference/future_then_upwards_2.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_upwards_2.dart.strong.transformed.expect
@@ -37,7 +37,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method main() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_upwards_3.dart.outline.expect b/pkg/front_end/testcases/inference/future_then_upwards_3.dart.outline.expect
index 4d4f3b9..5e50ec9 100644
--- a/pkg/front_end/testcases/inference/future_then_upwards_3.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_then_upwards_3.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void
diff --git a/pkg/front_end/testcases/inference/future_then_upwards_3.dart.strong.expect b/pkg/front_end/testcases/inference/future_then_upwards_3.dart.strong.expect
index 716490e..b19ec32 100644
--- a/pkg/front_end/testcases/inference/future_then_upwards_3.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_then_upwards_3.dart.strong.expect
@@ -37,7 +37,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_then_upwards_3.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_then_upwards_3.dart.strong.transformed.expect
index d80dc98..c213ce8 100644
--- a/pkg/front_end/testcases/inference/future_then_upwards_3.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_then_upwards_3.dart.strong.transformed.expect
@@ -37,7 +37,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method test() → void {
diff --git a/pkg/front_end/testcases/inference/future_union_async_conditional.dart.outline.expect b/pkg/front_end/testcases/inference/future_union_async_conditional.dart.outline.expect
index 53919a4..fc9743f 100644
--- a/pkg/front_end/testcases/inference/future_union_async_conditional.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_union_async_conditional.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method g1(core::bool* x) → asy::Future<core::int*>* async
diff --git a/pkg/front_end/testcases/inference/future_union_async_conditional.dart.strong.expect b/pkg/front_end/testcases/inference/future_union_async_conditional.dart.strong.expect
index a996264..ea9473b 100644
--- a/pkg/front_end/testcases/inference/future_union_async_conditional.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_union_async_conditional.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method g1(core::bool* x) → asy::Future<core::int*>* async {
diff --git a/pkg/front_end/testcases/inference/future_union_async_conditional.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_union_async_conditional.dart.strong.transformed.expect
index 6f4a91b..19d7f5e 100644
--- a/pkg/front_end/testcases/inference/future_union_async_conditional.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_union_async_conditional.dart.strong.transformed.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method g1(core::bool* x) → asy::Future<core::int*>* /* originally async */ {
diff --git a/pkg/front_end/testcases/inference/future_union_async_conditional_2.dart.outline.expect b/pkg/front_end/testcases/inference/future_union_async_conditional_2.dart.outline.expect
index 53919a4..fc9743f 100644
--- a/pkg/front_end/testcases/inference/future_union_async_conditional_2.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_union_async_conditional_2.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method g1(core::bool* x) → asy::Future<core::int*>* async
diff --git a/pkg/front_end/testcases/inference/future_union_async_conditional_2.dart.strong.expect b/pkg/front_end/testcases/inference/future_union_async_conditional_2.dart.strong.expect
index 101a065..6ee66d9 100644
--- a/pkg/front_end/testcases/inference/future_union_async_conditional_2.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_union_async_conditional_2.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method g1(core::bool* x) → asy::Future<core::int*>* async {
diff --git a/pkg/front_end/testcases/inference/future_union_async_conditional_2.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_union_async_conditional_2.dart.strong.transformed.expect
index ea54343..fac7441 100644
--- a/pkg/front_end/testcases/inference/future_union_async_conditional_2.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_union_async_conditional_2.dart.strong.transformed.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static method g1(core::bool* x) → asy::Future<core::int*>* /* originally async */ {
diff --git a/pkg/front_end/testcases/inference/future_union_downwards.dart.outline.expect b/pkg/front_end/testcases/inference/future_union_downwards.dart.outline.expect
index 9ce2e52..68e6a5c 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static field self::MyFuture<dynamic>* f;
diff --git a/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.expect b/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.expect
index dc7ead1..5113eaf 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.expect
@@ -36,7 +36,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static field self::MyFuture<dynamic>* f;
diff --git a/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.transformed.expect
index a876f1e..b3b21ee 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.transformed.expect
@@ -36,7 +36,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static field self::MyFuture<dynamic>* f;
diff --git a/pkg/front_end/testcases/inference/future_union_downwards_2.dart.outline.expect b/pkg/front_end/testcases/inference/future_union_downwards_2.dart.outline.expect
index 9ce2e52..68e6a5c 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards_2.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards_2.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static field self::MyFuture<dynamic>* f;
diff --git a/pkg/front_end/testcases/inference/future_union_downwards_2.dart.strong.expect b/pkg/front_end/testcases/inference/future_union_downwards_2.dart.strong.expect
index f6db118..bf4fd10 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards_2.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards_2.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static field self::MyFuture<dynamic>* f;
diff --git a/pkg/front_end/testcases/inference/future_union_downwards_2.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_union_downwards_2.dart.strong.transformed.expect
index 1d4203f..08408e4 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards_2.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards_2.dart.strong.transformed.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static field self::MyFuture<dynamic>* f;
diff --git a/pkg/front_end/testcases/inference/future_union_downwards_3.dart.outline.expect b/pkg/front_end/testcases/inference/future_union_downwards_3.dart.outline.expect
index a366aa3..be78378 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards_3.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards_3.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static field asy::Future<dynamic>* f;
diff --git a/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.expect b/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.expect
index 1f9668b..b52cf7b 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.expect
@@ -36,7 +36,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static field asy::Future<dynamic>* f;
diff --git a/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.transformed.expect
index 61d0c65c..1a3f92b 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.transformed.expect
@@ -36,7 +36,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static field asy::Future<dynamic>* f;
diff --git a/pkg/front_end/testcases/inference/future_union_downwards_4.dart.outline.expect b/pkg/front_end/testcases/inference/future_union_downwards_4.dart.outline.expect
index a366aa3..be78378 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards_4.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards_4.dart.outline.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static field asy::Future<dynamic>* f;
diff --git a/pkg/front_end/testcases/inference/future_union_downwards_4.dart.strong.expect b/pkg/front_end/testcases/inference/future_union_downwards_4.dart.strong.expect
index a94b936..8ce0d07 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards_4.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards_4.dart.strong.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static field asy::Future<dynamic>* f;
diff --git a/pkg/front_end/testcases/inference/future_union_downwards_4.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_union_downwards_4.dart.strong.transformed.expect
index 5c71651..578bc3b 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards_4.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards_4.dart.strong.transformed.expect
@@ -29,7 +29,7 @@
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
no-such-method-forwarder method asStream() → asy::Stream<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic} asy::Stream<self::MyFuture::T*>*;
- no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
+ no-such-method-forwarder method timeout(core::Duration* timeLimit, {generic-covariant-impl () →* FutureOr<self::MyFuture::T*>* onTimeout = #C1}) → asy::Future<self::MyFuture::T*>*
return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withType(#C9, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C10: onTimeout}))) as{TypeError,ForDynamic} asy::Future<self::MyFuture::T*>*;
}
static field asy::Future<dynamic>* f;
diff --git a/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart.outline.expect b/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart.outline.expect
index fc2eda8..91c3ff0 100644
--- a/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart.outline.expect
@@ -8,6 +8,7 @@
// ^
//
// pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart:9:20: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// var v = (f<dynamic>)(/*@returnType=int**/() {
// ^
//
diff --git a/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart.strong.expect b/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart.strong.expect
index a9f015e..2e3ca1e6 100644
--- a/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart.strong.expect
@@ -8,6 +8,7 @@
// ^
//
// pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart:9:20: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// var v = (f<dynamic>)(/*@returnType=int**/() {
// ^
//
diff --git a/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart.strong.transformed.expect
index a9f015e..2e3ca1e6 100644
--- a/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart.strong.transformed.expect
@@ -8,6 +8,7 @@
// ^
//
// pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_dynamic_param_via_expr1.dart:9:20: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// var v = (f<dynamic>)(/*@returnType=int**/() {
// ^
//
diff --git a/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart.outline.expect b/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart.outline.expect
index 767988c..ac5f82d 100644
--- a/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart.outline.expect
+++ b/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart.outline.expect
@@ -8,6 +8,7 @@
// ^
//
// pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart:9:16: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// var v = (f<int>)(/*@returnType=int**/() {
// ^
//
diff --git a/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart.strong.expect b/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart.strong.expect
index e7e43df..938f89a 100644
--- a/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart.strong.expect
@@ -8,6 +8,7 @@
// ^
//
// pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart:9:16: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// var v = (f<int>)(/*@returnType=int**/() {
// ^
//
diff --git a/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart.strong.transformed.expect
index e7e43df..938f89a 100644
--- a/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart.strong.transformed.expect
@@ -8,6 +8,7 @@
// ^
//
// pkg/front_end/testcases/inference/unsafe_block_closure_inference_function_call_explicit_type_param_via_expr1.dart:9:16: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// var v = (f<int>)(/*@returnType=int**/() {
// ^
//
diff --git a/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.strong.expect b/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.strong.expect
index 82f387d..af326bf 100644
--- a/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.strong.expect
@@ -3,10 +3,12 @@
// Problems in library:
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:7:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:8:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42] = 42;
// ^
//
@@ -15,6 +17,7 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:9:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]++;
// ^
//
@@ -23,6 +26,7 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:10:8: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// ++c?.[42];
// ^
//
@@ -31,18 +35,22 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:11:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:11:12: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:12:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0] ??= 42;
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:12:12: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0] ??= 42;
// ^
//
@@ -51,10 +59,12 @@
// ^^^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0]++;
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:12: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0]++;
// ^
//
@@ -63,10 +73,12 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:8: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// ++c?.[42]?.[0];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:14: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// ++c?.[42]?.[0];
// ^
//
@@ -79,6 +91,7 @@
static method main() → dynamic {
dynamic c;
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:7:6: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42];
^";
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:8:11: Error: Can't assign to this.
@@ -87,14 +100,17 @@
let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:9:6: Error: Can't assign to this.
c?.[42]++;
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:9:6: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42]++;
^";
let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:10:8: Error: Can't assign to this.
++c?.[42];
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:10:8: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
++c?.[42];
^";
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:11:12: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42]?.[0];
^";
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:12:16: Error: Can't assign to this.
@@ -103,11 +119,13 @@
let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:12: Error: Can't assign to this.
c?.[42]?.[0]++;
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:12: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42]?.[0]++;
^";
let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:14: Error: Can't assign to this.
++c?.[42]?.[0];
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:14: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
++c?.[42]?.[0];
^";
}
diff --git a/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.strong.transformed.expect
index 82f387d..af326bf 100644
--- a/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.strong.transformed.expect
@@ -3,10 +3,12 @@
// Problems in library:
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:7:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:8:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42] = 42;
// ^
//
@@ -15,6 +17,7 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:9:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]++;
// ^
//
@@ -23,6 +26,7 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:10:8: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// ++c?.[42];
// ^
//
@@ -31,18 +35,22 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:11:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:11:12: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:12:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0] ??= 42;
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:12:12: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0] ??= 42;
// ^
//
@@ -51,10 +59,12 @@
// ^^^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0]++;
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:12: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0]++;
// ^
//
@@ -63,10 +73,12 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:8: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// ++c?.[42]?.[0];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:14: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// ++c?.[42]?.[0];
// ^
//
@@ -79,6 +91,7 @@
static method main() → dynamic {
dynamic c;
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:7:6: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42];
^";
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:8:11: Error: Can't assign to this.
@@ -87,14 +100,17 @@
let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:9:6: Error: Can't assign to this.
c?.[42]++;
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:9:6: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42]++;
^";
let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:10:8: Error: Can't assign to this.
++c?.[42];
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:10:8: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
++c?.[42];
^";
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:11:12: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42]?.[0];
^";
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:12:16: Error: Can't assign to this.
@@ -103,11 +119,13 @@
let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:12: Error: Can't assign to this.
c?.[42]?.[0]++;
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:12: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42]?.[0]++;
^";
let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:14: Error: Can't assign to this.
++c?.[42]?.[0];
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:14: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
++c?.[42]?.[0];
^";
}
diff --git a/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.weak.expect b/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.weak.expect
index 82f387d..af326bf 100644
--- a/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.weak.expect
@@ -3,10 +3,12 @@
// Problems in library:
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:7:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:8:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42] = 42;
// ^
//
@@ -15,6 +17,7 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:9:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]++;
// ^
//
@@ -23,6 +26,7 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:10:8: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// ++c?.[42];
// ^
//
@@ -31,18 +35,22 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:11:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:11:12: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:12:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0] ??= 42;
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:12:12: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0] ??= 42;
// ^
//
@@ -51,10 +59,12 @@
// ^^^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0]++;
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:12: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0]++;
// ^
//
@@ -63,10 +73,12 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:8: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// ++c?.[42]?.[0];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:14: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// ++c?.[42]?.[0];
// ^
//
@@ -79,6 +91,7 @@
static method main() → dynamic {
dynamic c;
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:7:6: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42];
^";
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:8:11: Error: Can't assign to this.
@@ -87,14 +100,17 @@
let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:9:6: Error: Can't assign to this.
c?.[42]++;
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:9:6: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42]++;
^";
let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:10:8: Error: Can't assign to this.
++c?.[42];
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:10:8: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
++c?.[42];
^";
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:11:12: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42]?.[0];
^";
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:12:16: Error: Can't assign to this.
@@ -103,11 +119,13 @@
let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:12: Error: Can't assign to this.
c?.[42]?.[0]++;
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:12: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42]?.[0]++;
^";
let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:14: Error: Can't assign to this.
++c?.[42]?.[0];
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:14: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
++c?.[42]?.[0];
^";
}
diff --git a/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.weak.transformed.expect
index 82f387d..af326bf 100644
--- a/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart.weak.transformed.expect
@@ -3,10 +3,12 @@
// Problems in library:
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:7:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:8:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42] = 42;
// ^
//
@@ -15,6 +17,7 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:9:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]++;
// ^
//
@@ -23,6 +26,7 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:10:8: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// ++c?.[42];
// ^
//
@@ -31,18 +35,22 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:11:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:11:12: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:12:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0] ??= 42;
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:12:12: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0] ??= 42;
// ^
//
@@ -51,10 +59,12 @@
// ^^^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:6: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0]++;
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:12: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// c?.[42]?.[0]++;
// ^
//
@@ -63,10 +73,12 @@
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:8: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// ++c?.[42]?.[0];
// ^
//
// pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:14: Error: Expected an identifier, but got '['.
+// Try inserting an identifier before '['.
// ++c?.[42]?.[0];
// ^
//
@@ -79,6 +91,7 @@
static method main() → dynamic {
dynamic c;
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:7:6: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42];
^";
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:8:11: Error: Can't assign to this.
@@ -87,14 +100,17 @@
let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:9:6: Error: Can't assign to this.
c?.[42]++;
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:9:6: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42]++;
^";
let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:10:8: Error: Can't assign to this.
++c?.[42];
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:10:8: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
++c?.[42];
^";
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:11:12: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42]?.[0];
^";
invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:12:16: Error: Can't assign to this.
@@ -103,11 +119,13 @@
let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:12: Error: Can't assign to this.
c?.[42]?.[0]++;
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:13:12: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
c?.[42]?.[0]++;
^";
let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:14: Error: Can't assign to this.
++c?.[42]?.[0];
^" in invalid-expression "pkg/front_end/testcases/nnbd/no_support_for_old_null_aware_index_access_syntax.dart:14:14: Error: Expected an identifier, but got '['.
+Try inserting an identifier before '['.
++c?.[42]?.[0];
^";
}
diff --git a/pkg/front_end/testcases/nnbd_mixed/issue41597.dart.weak.expect b/pkg/front_end/testcases/nnbd_mixed/issue41597.dart.weak.expect
index d17df18..af178d3 100644
--- a/pkg/front_end/testcases/nnbd_mixed/issue41597.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd_mixed/issue41597.dart.weak.expect
@@ -73,26 +73,32 @@
// Problems in library:
//
// pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:8:6: Error: Expected an identifier, but got '.'.
+// Try inserting an identifier before '.'.
// c?..f;
// ^
//
// pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:8:6: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// c?..f;
// ^
//
// pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:9:7: Error: Expected an identifier, but got '.'.
+// Try inserting an identifier before '.'.
// !c?..f;
// ^
//
// pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:9:7: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// !c?..f;
// ^
//
// pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:10:6: Error: Expected an identifier, but got '.'.
+// Try inserting an identifier before '.'.
// c?..f!;
// ^
//
// pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:10:6: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// c?..f!;
// ^
//
@@ -109,12 +115,15 @@
static method errors(dynamic c) → dynamic {
invalid-expression "pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:8:6: Error: Expected an identifier, but got ''.
+Try inserting an identifier before ''.
c?..f;
^".f;
!(invalid-expression "pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:9:7: Error: Expected an identifier, but got ''.
+Try inserting an identifier before ''.
!c?..f;
^".f as{TypeError,ForDynamic} core::bool*);
invalid-expression "pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:10:6: Error: Expected an identifier, but got ''.
+Try inserting an identifier before ''.
c?..f!;
^".f!;
}
diff --git a/pkg/front_end/testcases/nnbd_mixed/issue41597.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd_mixed/issue41597.dart.weak.transformed.expect
index d14676f..d3c36df 100644
--- a/pkg/front_end/testcases/nnbd_mixed/issue41597.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd_mixed/issue41597.dart.weak.transformed.expect
@@ -73,26 +73,32 @@
// Problems in library:
//
// pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:8:6: Error: Expected an identifier, but got '.'.
+// Try inserting an identifier before '.'.
// c?..f;
// ^
//
// pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:8:6: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// c?..f;
// ^
//
// pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:9:7: Error: Expected an identifier, but got '.'.
+// Try inserting an identifier before '.'.
// !c?..f;
// ^
//
// pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:9:7: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// !c?..f;
// ^
//
// pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:10:6: Error: Expected an identifier, but got '.'.
+// Try inserting an identifier before '.'.
// c?..f!;
// ^
//
// pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:10:6: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// c?..f!;
// ^
//
@@ -109,12 +115,15 @@
static method errors(dynamic c) → dynamic {
invalid-expression "pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:8:6: Error: Expected an identifier, but got ''.
+Try inserting an identifier before ''.
c?..f;
^".f;
!(invalid-expression "pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:9:7: Error: Expected an identifier, but got ''.
+Try inserting an identifier before ''.
!c?..f;
^".f as{TypeError,ForDynamic} core::bool*);
invalid-expression "pkg/front_end/testcases/nnbd_mixed/issue41597_lib.dart:10:6: Error: Expected an identifier, but got ''.
+Try inserting an identifier before ''.
c?..f!;
^".f!;
}
diff --git a/pkg/front_end/testcases/nnbd_mixed/opt_out.dart.weak.expect b/pkg/front_end/testcases/nnbd_mixed/opt_out.dart.weak.expect
index 2c1fe98..3869af1 100644
--- a/pkg/front_end/testcases/nnbd_mixed/opt_out.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd_mixed/opt_out.dart.weak.expect
@@ -116,10 +116,12 @@
// ^^^^^^^^^^^^
//
// pkg/front_end/testcases/nnbd_mixed/opt_out_lib.dart:36:6: Error: Expected an identifier, but got '.'.
+// Try inserting an identifier before '.'.
// c?..f;
// ^
//
// pkg/front_end/testcases/nnbd_mixed/opt_out_lib.dart:36:6: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// c?..f;
// ^
//
@@ -168,6 +170,7 @@
core::String* t = s!;
dynamic c;
invalid-expression "pkg/front_end/testcases/nnbd_mixed/opt_out_lib.dart:36:6: Error: Expected an identifier, but got ''.
+Try inserting an identifier before ''.
c?..f;
^".f;
let final dynamic #t3 = c in #t3.{core::Object::==}(null) ?{dynamic} null : #t3.[](0);
diff --git a/pkg/front_end/testcases/nnbd_mixed/opt_out.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd_mixed/opt_out.dart.weak.transformed.expect
index 2c1fe98..3869af1 100644
--- a/pkg/front_end/testcases/nnbd_mixed/opt_out.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd_mixed/opt_out.dart.weak.transformed.expect
@@ -116,10 +116,12 @@
// ^^^^^^^^^^^^
//
// pkg/front_end/testcases/nnbd_mixed/opt_out_lib.dart:36:6: Error: Expected an identifier, but got '.'.
+// Try inserting an identifier before '.'.
// c?..f;
// ^
//
// pkg/front_end/testcases/nnbd_mixed/opt_out_lib.dart:36:6: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// c?..f;
// ^
//
@@ -168,6 +170,7 @@
core::String* t = s!;
dynamic c;
invalid-expression "pkg/front_end/testcases/nnbd_mixed/opt_out_lib.dart:36:6: Error: Expected an identifier, but got ''.
+Try inserting an identifier before ''.
c?..f;
^".f;
let final dynamic #t3 = c in #t3.{core::Object::==}(null) ?{dynamic} null : #t3.[](0);
diff --git a/pkg/front_end/testcases/rasta/issue_000032.dart.outline.expect b/pkg/front_end/testcases/rasta/issue_000032.dart.outline.expect
index efbb1fc..d9fcdaf 100644
--- a/pkg/front_end/testcases/rasta/issue_000032.dart.outline.expect
+++ b/pkg/front_end/testcases/rasta/issue_000032.dart.outline.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/rasta/issue_000032.dart:7:1: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// }
// ^
//
diff --git a/pkg/front_end/testcases/rasta/issue_000032.dart.strong.expect b/pkg/front_end/testcases/rasta/issue_000032.dart.strong.expect
index 7fcff63..9cae185 100644
--- a/pkg/front_end/testcases/rasta/issue_000032.dart.strong.expect
+++ b/pkg/front_end/testcases/rasta/issue_000032.dart.strong.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/rasta/issue_000032.dart:7:1: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// }
// ^
//
@@ -21,6 +22,7 @@
// ^
//
// pkg/front_end/testcases/rasta/issue_000032.dart:11:1: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// }
// ^
//
diff --git a/pkg/front_end/testcases/rasta/issue_000032.dart.strong.transformed.expect b/pkg/front_end/testcases/rasta/issue_000032.dart.strong.transformed.expect
index 7fcff63..9cae185 100644
--- a/pkg/front_end/testcases/rasta/issue_000032.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/rasta/issue_000032.dart.strong.transformed.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/rasta/issue_000032.dart:7:1: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// }
// ^
//
@@ -21,6 +22,7 @@
// ^
//
// pkg/front_end/testcases/rasta/issue_000032.dart:11:1: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// }
// ^
//
diff --git a/pkg/front_end/testcases/rasta/issue_000036.dart.outline.expect b/pkg/front_end/testcases/rasta/issue_000036.dart.outline.expect
index 14f3ce3..9e8c916 100644
--- a/pkg/front_end/testcases/rasta/issue_000036.dart.outline.expect
+++ b/pkg/front_end/testcases/rasta/issue_000036.dart.outline.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/rasta/issue_000036.dart:5:14: Error: Expected an identifier, but got '-'.
+// Try inserting an identifier before '-'.
// main() => a. - 5;
// ^
//
diff --git a/pkg/front_end/testcases/rasta/issue_000036.dart.strong.expect b/pkg/front_end/testcases/rasta/issue_000036.dart.strong.expect
index c46dc5c..433f8d9 100644
--- a/pkg/front_end/testcases/rasta/issue_000036.dart.strong.expect
+++ b/pkg/front_end/testcases/rasta/issue_000036.dart.strong.expect
@@ -3,10 +3,12 @@
// Problems in library:
//
// pkg/front_end/testcases/rasta/issue_000036.dart:5:14: Error: Expected an identifier, but got '-'.
+// Try inserting an identifier before '-'.
// main() => a. - 5;
// ^
//
// pkg/front_end/testcases/rasta/issue_000036.dart:5:14: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// main() => a. - 5;
// ^
//
@@ -14,5 +16,6 @@
static method main() → dynamic
return invalid-expression "pkg/front_end/testcases/rasta/issue_000036.dart:5:14: Error: Expected an identifier, but got ''.
+Try inserting an identifier before ''.
main() => a. - 5;
^".-(5);
diff --git a/pkg/front_end/testcases/rasta/issue_000036.dart.strong.transformed.expect b/pkg/front_end/testcases/rasta/issue_000036.dart.strong.transformed.expect
index c46dc5c..433f8d9 100644
--- a/pkg/front_end/testcases/rasta/issue_000036.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/rasta/issue_000036.dart.strong.transformed.expect
@@ -3,10 +3,12 @@
// Problems in library:
//
// pkg/front_end/testcases/rasta/issue_000036.dart:5:14: Error: Expected an identifier, but got '-'.
+// Try inserting an identifier before '-'.
// main() => a. - 5;
// ^
//
// pkg/front_end/testcases/rasta/issue_000036.dart:5:14: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// main() => a. - 5;
// ^
//
@@ -14,5 +16,6 @@
static method main() → dynamic
return invalid-expression "pkg/front_end/testcases/rasta/issue_000036.dart:5:14: Error: Expected an identifier, but got ''.
+Try inserting an identifier before ''.
main() => a. - 5;
^".-(5);
diff --git a/pkg/front_end/testcases/rasta/issue_000039.dart.strong.expect b/pkg/front_end/testcases/rasta/issue_000039.dart.strong.expect
index 293d1e6..238ce88 100644
--- a/pkg/front_end/testcases/rasta/issue_000039.dart.strong.expect
+++ b/pkg/front_end/testcases/rasta/issue_000039.dart.strong.expect
@@ -3,10 +3,12 @@
// Problems in library:
//
// pkg/front_end/testcases/rasta/issue_000039.dart:10:3: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// }
// ^
//
// pkg/front_end/testcases/rasta/issue_000039.dart:10:3: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// }
// ^
//
@@ -26,6 +28,7 @@
constructor •(dynamic x) → self::A*
: super core::Object::•() {
this.{self::A::a} = invalid-expression "pkg/front_end/testcases/rasta/issue_000039.dart:10:3: Error: Expected an identifier, but got ''.
+Try inserting an identifier before ''.
}
^";
}
diff --git a/pkg/front_end/testcases/rasta/issue_000039.dart.strong.transformed.expect b/pkg/front_end/testcases/rasta/issue_000039.dart.strong.transformed.expect
index 293d1e6..238ce88 100644
--- a/pkg/front_end/testcases/rasta/issue_000039.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/rasta/issue_000039.dart.strong.transformed.expect
@@ -3,10 +3,12 @@
// Problems in library:
//
// pkg/front_end/testcases/rasta/issue_000039.dart:10:3: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// }
// ^
//
// pkg/front_end/testcases/rasta/issue_000039.dart:10:3: Error: Expected an identifier, but got ''.
+// Try inserting an identifier before ''.
// }
// ^
//
@@ -26,6 +28,7 @@
constructor •(dynamic x) → self::A*
: super core::Object::•() {
this.{self::A::a} = invalid-expression "pkg/front_end/testcases/rasta/issue_000039.dart:10:3: Error: Expected an identifier, but got ''.
+Try inserting an identifier before ''.
}
^";
}
diff --git a/pkg/front_end/testcases/rasta/issue_000046.dart.outline.expect b/pkg/front_end/testcases/rasta/issue_000046.dart.outline.expect
index 4a4defd..204c7a9 100644
--- a/pkg/front_end/testcases/rasta/issue_000046.dart.outline.expect
+++ b/pkg/front_end/testcases/rasta/issue_000046.dart.outline.expect
@@ -15,6 +15,7 @@
// ^
//
// pkg/front_end/testcases/rasta/issue_000046.dart:6:20: Error: Expected an identifier, but got '('.
+// Try inserting an identifier before '('.
// C c = new Object)();
// ^
//
diff --git a/pkg/front_end/testcases/rasta/issue_000046.dart.strong.expect b/pkg/front_end/testcases/rasta/issue_000046.dart.strong.expect
index a724b05..7cade84 100644
--- a/pkg/front_end/testcases/rasta/issue_000046.dart.strong.expect
+++ b/pkg/front_end/testcases/rasta/issue_000046.dart.strong.expect
@@ -15,6 +15,7 @@
// ^
//
// pkg/front_end/testcases/rasta/issue_000046.dart:6:20: Error: Expected an identifier, but got '('.
+// Try inserting an identifier before '('.
// C c = new Object)();
// ^
//
diff --git a/pkg/front_end/testcases/rasta/issue_000046.dart.strong.transformed.expect b/pkg/front_end/testcases/rasta/issue_000046.dart.strong.transformed.expect
index a724b05..7cade84 100644
--- a/pkg/front_end/testcases/rasta/issue_000046.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/rasta/issue_000046.dart.strong.transformed.expect
@@ -15,6 +15,7 @@
// ^
//
// pkg/front_end/testcases/rasta/issue_000046.dart:6:20: Error: Expected an identifier, but got '('.
+// Try inserting an identifier before '('.
// C c = new Object)();
// ^
//
diff --git a/pkg/front_end/testcases/rasta/parser_error.dart.strong.expect b/pkg/front_end/testcases/rasta/parser_error.dart.strong.expect
index 13f78fd..1b9b0f8 100644
--- a/pkg/front_end/testcases/rasta/parser_error.dart.strong.expect
+++ b/pkg/front_end/testcases/rasta/parser_error.dart.strong.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/rasta/parser_error.dart:10:7: Error: Expected an identifier, but got '?'.
+// Try inserting an identifier before '?'.
// if (?b) return b; /// 01: compile-time error
// ^
//
@@ -11,6 +12,7 @@
// ^
//
// pkg/front_end/testcases/rasta/parser_error.dart:10:9: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// if (?b) return b; /// 01: compile-time error
// ^
//
diff --git a/pkg/front_end/testcases/rasta/parser_error.dart.strong.transformed.expect b/pkg/front_end/testcases/rasta/parser_error.dart.strong.transformed.expect
index 104ab44..a7bf51f 100644
--- a/pkg/front_end/testcases/rasta/parser_error.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/rasta/parser_error.dart.strong.transformed.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/rasta/parser_error.dart:10:7: Error: Expected an identifier, but got '?'.
+// Try inserting an identifier before '?'.
// if (?b) return b; /// 01: compile-time error
// ^
//
@@ -11,6 +12,7 @@
// ^
//
// pkg/front_end/testcases/rasta/parser_error.dart:10:9: Error: Expected an identifier, but got ')'.
+// Try inserting an identifier before ')'.
// if (?b) return b; /// 01: compile-time error
// ^
//
diff --git a/pkg/front_end/testcases/rasta/unresolved_for_in.dart.strong.expect b/pkg/front_end/testcases/rasta/unresolved_for_in.dart.strong.expect
index 814c1f0..8a74c31 100644
--- a/pkg/front_end/testcases/rasta/unresolved_for_in.dart.strong.expect
+++ b/pkg/front_end/testcases/rasta/unresolved_for_in.dart.strong.expect
@@ -19,6 +19,7 @@
// ^^^^^^^^^^^^
//
// pkg/front_end/testcases/rasta/unresolved_for_in.dart:23:10: Error: Expected an identifier, but got '1'.
+// Try inserting an identifier before '1'.
// for (1 in x) {
// ^
//
@@ -69,6 +70,7 @@
// ^^^^^^^^^^^^
//
// pkg/front_end/testcases/rasta/unresolved_for_in.dart:43:8: Error: Expected an identifier, but got '1'.
+// Try inserting an identifier before '1'.
// for (1 in arguments) {
// ^
//
diff --git a/pkg/front_end/testcases/rasta/unresolved_for_in.dart.strong.transformed.expect b/pkg/front_end/testcases/rasta/unresolved_for_in.dart.strong.transformed.expect
index 1e0dee4..c943cfc 100644
--- a/pkg/front_end/testcases/rasta/unresolved_for_in.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/rasta/unresolved_for_in.dart.strong.transformed.expect
@@ -19,6 +19,7 @@
// ^^^^^^^^^^^^
//
// pkg/front_end/testcases/rasta/unresolved_for_in.dart:23:10: Error: Expected an identifier, but got '1'.
+// Try inserting an identifier before '1'.
// for (1 in x) {
// ^
//
@@ -69,6 +70,7 @@
// ^^^^^^^^^^^^
//
// pkg/front_end/testcases/rasta/unresolved_for_in.dart:43:8: Error: Expected an identifier, but got '1'.
+// Try inserting an identifier before '1'.
// for (1 in arguments) {
// ^
//
diff --git a/pkg/front_end/testcases/rasta/unresolved_recovery.dart.strong.expect b/pkg/front_end/testcases/rasta/unresolved_recovery.dart.strong.expect
index 6906158..85bcb06 100644
--- a/pkg/front_end/testcases/rasta/unresolved_recovery.dart.strong.expect
+++ b/pkg/front_end/testcases/rasta/unresolved_recovery.dart.strong.expect
@@ -26,7 +26,8 @@
// on Exception catch (e) { }
// ^^^^^^^^^
//
-// pkg/front_end/testcases/rasta/unresolved_recovery.dart:20:16: Error: Expected an identifier, but got 'catch'.
+// pkg/front_end/testcases/rasta/unresolved_recovery.dart:20:16: Error: 'catch' can't be used as an identifier because it's a keyword.
+// Try renaming this to be an identifier that isn't a keyword.
// on Exception catch (e) { }
// ^^^^^
//
diff --git a/pkg/front_end/testcases/regress/issue_29941.dart.strong.expect b/pkg/front_end/testcases/regress/issue_29941.dart.strong.expect
index 5fc0850..82b995b 100644
--- a/pkg/front_end/testcases/regress/issue_29941.dart.strong.expect
+++ b/pkg/front_end/testcases/regress/issue_29941.dart.strong.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_29941.dart:7:5: Error: Expected an identifier, but got '""'.
+// Try inserting an identifier before '""'.
// a."";
// ^^
//
@@ -12,6 +13,7 @@
static method bad() → dynamic {
core::String* a = "";
invalid-expression "pkg/front_end/testcases/regress/issue_29941.dart:7:5: Error: Expected an identifier, but got '\"\"'.
+Try inserting an identifier before '\"\"'.
a.\"\";
^^";
}
diff --git a/pkg/front_end/testcases/regress/issue_29941.dart.strong.transformed.expect b/pkg/front_end/testcases/regress/issue_29941.dart.strong.transformed.expect
index 5fc0850..82b995b 100644
--- a/pkg/front_end/testcases/regress/issue_29941.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/regress/issue_29941.dart.strong.transformed.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_29941.dart:7:5: Error: Expected an identifier, but got '""'.
+// Try inserting an identifier before '""'.
// a."";
// ^^
//
@@ -12,6 +13,7 @@
static method bad() → dynamic {
core::String* a = "";
invalid-expression "pkg/front_end/testcases/regress/issue_29941.dart:7:5: Error: Expected an identifier, but got '\"\"'.
+Try inserting an identifier before '\"\"'.
a.\"\";
^^";
}
diff --git a/pkg/front_end/testcases/regress/issue_29943.dart.strong.expect b/pkg/front_end/testcases/regress/issue_29943.dart.strong.expect
index 4684ec6..cc07a5e 100644
--- a/pkg/front_end/testcases/regress/issue_29943.dart.strong.expect
+++ b/pkg/front_end/testcases/regress/issue_29943.dart.strong.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_29943.dart:6:5: Error: Expected an identifier, but got '('.
+// Try inserting an identifier before '('.
// x.(null);
// ^
//
@@ -10,6 +11,7 @@
static method bad() → dynamic {
invalid-expression "pkg/front_end/testcases/regress/issue_29943.dart:6:5: Error: Expected an identifier, but got '('.
+Try inserting an identifier before '('.
x.(null);
^";
}
diff --git a/pkg/front_end/testcases/regress/issue_29943.dart.strong.transformed.expect b/pkg/front_end/testcases/regress/issue_29943.dart.strong.transformed.expect
index 4684ec6..cc07a5e 100644
--- a/pkg/front_end/testcases/regress/issue_29943.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/regress/issue_29943.dart.strong.transformed.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_29943.dart:6:5: Error: Expected an identifier, but got '('.
+// Try inserting an identifier before '('.
// x.(null);
// ^
//
@@ -10,6 +11,7 @@
static method bad() → dynamic {
invalid-expression "pkg/front_end/testcases/regress/issue_29943.dart:6:5: Error: Expected an identifier, but got '('.
+Try inserting an identifier before '('.
x.(null);
^";
}
diff --git a/pkg/front_end/testcases/regress/issue_31157.dart.strong.expect b/pkg/front_end/testcases/regress/issue_31157.dart.strong.expect
index f102486..f999813 100644
--- a/pkg/front_end/testcases/regress/issue_31157.dart.strong.expect
+++ b/pkg/front_end/testcases/regress/issue_31157.dart.strong.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_31157.dart:6:16: Error: Expected an identifier, but got '('.
+// Try inserting an identifier before '('.
// return null?.(1);
// ^
//
@@ -10,6 +11,7 @@
static method bad() → dynamic {
return invalid-expression "pkg/front_end/testcases/regress/issue_31157.dart:6:16: Error: Expected an identifier, but got '('.
+Try inserting an identifier before '('.
return null?.(1);
^";
}
diff --git a/pkg/front_end/testcases/regress/issue_31157.dart.strong.transformed.expect b/pkg/front_end/testcases/regress/issue_31157.dart.strong.transformed.expect
index f102486..f999813 100644
--- a/pkg/front_end/testcases/regress/issue_31157.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/regress/issue_31157.dart.strong.transformed.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_31157.dart:6:16: Error: Expected an identifier, but got '('.
+// Try inserting an identifier before '('.
// return null?.(1);
// ^
//
@@ -10,6 +11,7 @@
static method bad() → dynamic {
return invalid-expression "pkg/front_end/testcases/regress/issue_31157.dart:6:16: Error: Expected an identifier, but got '('.
+Try inserting an identifier before '('.
return null?.(1);
^";
}
diff --git a/pkg/front_end/testcases/regress/issue_31184.dart.strong.expect b/pkg/front_end/testcases/regress/issue_31184.dart.strong.expect
index ed5c611..059fa66 100644
--- a/pkg/front_end/testcases/regress/issue_31184.dart.strong.expect
+++ b/pkg/front_end/testcases/regress/issue_31184.dart.strong.expect
@@ -14,6 +14,7 @@
// ^
//
// pkg/front_end/testcases/regress/issue_31184.dart:6:21: Error: Expected an identifier, but got '>'.
+// Try inserting an identifier before '>'.
// for (int i = 0, i > 10; i++) {}
// ^
//
diff --git a/pkg/front_end/testcases/regress/issue_31184.dart.strong.transformed.expect b/pkg/front_end/testcases/regress/issue_31184.dart.strong.transformed.expect
index 57aaf8d..5737a9e 100644
--- a/pkg/front_end/testcases/regress/issue_31184.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/regress/issue_31184.dart.strong.transformed.expect
@@ -14,6 +14,7 @@
// ^
//
// pkg/front_end/testcases/regress/issue_31184.dart:6:21: Error: Expected an identifier, but got '>'.
+// Try inserting an identifier before '>'.
// for (int i = 0, i > 10; i++) {}
// ^
//
diff --git a/pkg/front_end/testcases/regress/issue_31186.dart.strong.expect b/pkg/front_end/testcases/regress/issue_31186.dart.strong.expect
index 8f46e0f..ce4b4c6 100644
--- a/pkg/front_end/testcases/regress/issue_31186.dart.strong.expect
+++ b/pkg/front_end/testcases/regress/issue_31186.dart.strong.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_31186.dart:6:16: Error: Expected an identifier, but got 'true'.
+// Try inserting an identifier before 'true'.
// return null?.true;
// ^^^^
//
@@ -10,6 +11,7 @@
static method bad() → dynamic {
return invalid-expression "pkg/front_end/testcases/regress/issue_31186.dart:6:16: Error: Expected an identifier, but got 'true'.
+Try inserting an identifier before 'true'.
return null?.true;
^^^^";
}
diff --git a/pkg/front_end/testcases/regress/issue_31186.dart.strong.transformed.expect b/pkg/front_end/testcases/regress/issue_31186.dart.strong.transformed.expect
index 8f46e0f..ce4b4c6 100644
--- a/pkg/front_end/testcases/regress/issue_31186.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/regress/issue_31186.dart.strong.transformed.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_31186.dart:6:16: Error: Expected an identifier, but got 'true'.
+// Try inserting an identifier before 'true'.
// return null?.true;
// ^^^^
//
@@ -10,6 +11,7 @@
static method bad() → dynamic {
return invalid-expression "pkg/front_end/testcases/regress/issue_31186.dart:6:16: Error: Expected an identifier, but got 'true'.
+Try inserting an identifier before 'true'.
return null?.true;
^^^^";
}
diff --git a/pkg/front_end/testcases/regress/issue_31187.dart.strong.expect b/pkg/front_end/testcases/regress/issue_31187.dart.strong.expect
index 6126225..77462b2 100644
--- a/pkg/front_end/testcases/regress/issue_31187.dart.strong.expect
+++ b/pkg/front_end/testcases/regress/issue_31187.dart.strong.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_31187.dart:6:16: Error: Expected an identifier, but got '1'.
+// Try inserting an identifier before '1'.
// return null?.1;
// ^
//
@@ -10,6 +11,7 @@
static method bad() → dynamic {
return invalid-expression "pkg/front_end/testcases/regress/issue_31187.dart:6:16: Error: Expected an identifier, but got '1'.
+Try inserting an identifier before '1'.
return null?.1;
^";
}
diff --git a/pkg/front_end/testcases/regress/issue_31187.dart.strong.transformed.expect b/pkg/front_end/testcases/regress/issue_31187.dart.strong.transformed.expect
index 6126225..77462b2 100644
--- a/pkg/front_end/testcases/regress/issue_31187.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/regress/issue_31187.dart.strong.transformed.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_31187.dart:6:16: Error: Expected an identifier, but got '1'.
+// Try inserting an identifier before '1'.
// return null?.1;
// ^
//
@@ -10,6 +11,7 @@
static method bad() → dynamic {
return invalid-expression "pkg/front_end/testcases/regress/issue_31187.dart:6:16: Error: Expected an identifier, but got '1'.
+Try inserting an identifier before '1'.
return null?.1;
^";
}
diff --git a/pkg/front_end/testcases/regress/issue_34614.dart.outline.expect b/pkg/front_end/testcases/regress/issue_34614.dart.outline.expect
index 89401ca..3132fad 100644
--- a/pkg/front_end/testcases/regress/issue_34614.dart.outline.expect
+++ b/pkg/front_end/testcases/regress/issue_34614.dart.outline.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_34614.dart:5:14: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class C { C. }
// ^
//
diff --git a/pkg/front_end/testcases/regress/issue_34614.dart.strong.expect b/pkg/front_end/testcases/regress/issue_34614.dart.strong.expect
index e939413..c556791 100644
--- a/pkg/front_end/testcases/regress/issue_34614.dart.strong.expect
+++ b/pkg/front_end/testcases/regress/issue_34614.dart.strong.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_34614.dart:5:14: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class C { C. }
// ^
//
diff --git a/pkg/front_end/testcases/regress/issue_34614.dart.strong.transformed.expect b/pkg/front_end/testcases/regress/issue_34614.dart.strong.transformed.expect
index e939413..c556791 100644
--- a/pkg/front_end/testcases/regress/issue_34614.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/regress/issue_34614.dart.strong.transformed.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_34614.dart:5:14: Error: Expected an identifier, but got '}'.
+// Try inserting an identifier before '}'.
// class C { C. }
// ^
//
diff --git a/pkg/front_end/testcases/regress/issue_36647.dart.outline.expect b/pkg/front_end/testcases/regress/issue_36647.dart.outline.expect
index 8cd18d0..67b102e 100644
--- a/pkg/front_end/testcases/regress/issue_36647.dart.outline.expect
+++ b/pkg/front_end/testcases/regress/issue_36647.dart.outline.expect
@@ -32,7 +32,8 @@
// class xxx xx XXX extends XXX {
// ^^^^^^^
//
-// pkg/front_end/testcases/regress/issue_36647_lib2.dart:5:18: Error: Expected an identifier, but got 'extends'.
+// pkg/front_end/testcases/regress/issue_36647_lib2.dart:5:18: Error: 'extends' can't be used as an identifier because it's a keyword.
+// Try renaming this to be an identifier that isn't a keyword.
// class xxx xx XXX extends XXX {
// ^^^^^^^
//
diff --git a/pkg/front_end/testcases/regress/issue_36647.dart.strong.expect b/pkg/front_end/testcases/regress/issue_36647.dart.strong.expect
index 9c3c2e5..3ad0fc9 100644
--- a/pkg/front_end/testcases/regress/issue_36647.dart.strong.expect
+++ b/pkg/front_end/testcases/regress/issue_36647.dart.strong.expect
@@ -32,7 +32,8 @@
// class xxx xx XXX extends XXX {
// ^^^^^^^
//
-// pkg/front_end/testcases/regress/issue_36647_lib2.dart:5:18: Error: Expected an identifier, but got 'extends'.
+// pkg/front_end/testcases/regress/issue_36647_lib2.dart:5:18: Error: 'extends' can't be used as an identifier because it's a keyword.
+// Try renaming this to be an identifier that isn't a keyword.
// class xxx xx XXX extends XXX {
// ^^^^^^^
//
diff --git a/pkg/front_end/testcases/regress/issue_36647.dart.strong.transformed.expect b/pkg/front_end/testcases/regress/issue_36647.dart.strong.transformed.expect
index 9c3c2e5..3ad0fc9 100644
--- a/pkg/front_end/testcases/regress/issue_36647.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/regress/issue_36647.dart.strong.transformed.expect
@@ -32,7 +32,8 @@
// class xxx xx XXX extends XXX {
// ^^^^^^^
//
-// pkg/front_end/testcases/regress/issue_36647_lib2.dart:5:18: Error: Expected an identifier, but got 'extends'.
+// pkg/front_end/testcases/regress/issue_36647_lib2.dart:5:18: Error: 'extends' can't be used as an identifier because it's a keyword.
+// Try renaming this to be an identifier that isn't a keyword.
// class xxx xx XXX extends XXX {
// ^^^^^^^
//
diff --git a/pkg/front_end/testcases/regress/issue_37285.dart.outline.expect b/pkg/front_end/testcases/regress/issue_37285.dart.outline.expect
index eb023c1..ffc4431 100644
--- a/pkg/front_end/testcases/regress/issue_37285.dart.outline.expect
+++ b/pkg/front_end/testcases/regress/issue_37285.dart.outline.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_37285.dart:6:17: Error: Expected an identifier, but got ']'.
+// Try inserting an identifier before ']'.
// C() : super()[];
// ^
//
diff --git a/pkg/front_end/testcases/regress/issue_37285.dart.strong.expect b/pkg/front_end/testcases/regress/issue_37285.dart.strong.expect
index ffef555..84ceeef 100644
--- a/pkg/front_end/testcases/regress/issue_37285.dart.strong.expect
+++ b/pkg/front_end/testcases/regress/issue_37285.dart.strong.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_37285.dart:6:17: Error: Expected an identifier, but got ']'.
+// Try inserting an identifier before ']'.
// C() : super()[];
// ^
//
diff --git a/pkg/front_end/testcases/regress/issue_37285.dart.strong.transformed.expect b/pkg/front_end/testcases/regress/issue_37285.dart.strong.transformed.expect
index ffef555..84ceeef 100644
--- a/pkg/front_end/testcases/regress/issue_37285.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/regress/issue_37285.dart.strong.transformed.expect
@@ -3,6 +3,7 @@
// Problems in library:
//
// pkg/front_end/testcases/regress/issue_37285.dart:6:17: Error: Expected an identifier, but got ']'.
+// Try inserting an identifier before ']'.
// C() : super()[];
// ^
//
diff --git a/pkg/front_end/testcases/regress/issue_39035.crash_dart.outline.expect b/pkg/front_end/testcases/regress/issue_39035.crash_dart.outline.expect
index efb076e..19ddd7d 100644
--- a/pkg/front_end/testcases/regress/issue_39035.crash_dart.outline.expect
+++ b/pkg/front_end/testcases/regress/issue_39035.crash_dart.outline.expect
@@ -11,6 +11,7 @@
// ^^
//
// pkg/front_end/testcases/regress/issue_39035.crash_dart:5:3: Error: Expected an identifier, but got '"'.
+// Try inserting an identifier before '"'.
// M("${)=
// ^
//
diff --git a/pkg/front_end/testcases/regress/issue_39035.crash_dart.strong.expect b/pkg/front_end/testcases/regress/issue_39035.crash_dart.strong.expect
index 1a54007..255f4ae 100644
--- a/pkg/front_end/testcases/regress/issue_39035.crash_dart.strong.expect
+++ b/pkg/front_end/testcases/regress/issue_39035.crash_dart.strong.expect
@@ -11,6 +11,7 @@
// ^^
//
// pkg/front_end/testcases/regress/issue_39035.crash_dart:5:3: Error: Expected an identifier, but got '"'.
+// Try inserting an identifier before '"'.
// M("${)=
// ^
//
diff --git a/pkg/front_end/testcases/regress/issue_39035.crash_dart.strong.transformed.expect b/pkg/front_end/testcases/regress/issue_39035.crash_dart.strong.transformed.expect
index 1a54007..255f4ae 100644
--- a/pkg/front_end/testcases/regress/issue_39035.crash_dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/regress/issue_39035.crash_dart.strong.transformed.expect
@@ -11,6 +11,7 @@
// ^^
//
// pkg/front_end/testcases/regress/issue_39035.crash_dart:5:3: Error: Expected an identifier, but got '"'.
+// Try inserting an identifier before '"'.
// M("${)=
// ^
//
diff --git a/pkg/kernel/lib/src/legacy_erasure.dart b/pkg/kernel/lib/src/legacy_erasure.dart
index b7fa3e5..44a5d3a 100644
--- a/pkg/kernel/lib/src/legacy_erasure.dart
+++ b/pkg/kernel/lib/src/legacy_erasure.dart
@@ -56,7 +56,7 @@
_LegacyErasure(this.coreTypes);
Nullability visitNullability(DartType node) {
- if (node.nullability != Nullability.legacy) {
+ if (node.declaredNullability != Nullability.legacy) {
return Nullability.legacy;
}
return null;
diff --git a/tests/language/class/keyword_test.dart b/tests/language/class/keyword_test.dart
index 5a89f2e..8b07fec 100644
--- a/tests/language/class/keyword_test.dart
+++ b/tests/language/class/keyword_test.dart
@@ -13,15 +13,15 @@
// [cfe] Expected ';' after this.
// ^^^^^
// [analyzer] COMPILE_TIME_ERROR.UNDEFINED_IDENTIFIER
-// [cfe] Expected an identifier, but got 'class'.
+// [cfe] 'class' can't be used as an identifier because it's a keyword.
// ^^^^^
-// [analyzer] SYNTACTIC_ERROR.MISSING_IDENTIFIER
+// [analyzer] SYNTACTIC_ERROR.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD
// [cfe] Setter not found: 'class'.
print("$class");
// ^^^^^
// [analyzer] COMPILE_TIME_ERROR.UNDEFINED_IDENTIFIER
- // [cfe] Expected an identifier, but got 'class'.
+ // [cfe] 'class' can't be used as an identifier because it's a keyword.
// ^^^^^
- // [analyzer] SYNTACTIC_ERROR.MISSING_IDENTIFIER
+ // [analyzer] SYNTACTIC_ERROR.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD
// [cfe] Getter not found: 'class'.
}
diff --git a/tests/language/enum/is_keyword_test.dart b/tests/language/enum/is_keyword_test.dart
index 5e7d0b5..4d37239 100644
--- a/tests/language/enum/is_keyword_test.dart
+++ b/tests/language/enum/is_keyword_test.dart
@@ -8,6 +8,6 @@
main() {
var enum;
// ^^^^
- // [analyzer] SYNTACTIC_ERROR.MISSING_IDENTIFIER
- // [cfe] Expected an identifier, but got 'enum'.
+ // [analyzer] SYNTACTIC_ERROR.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD
+ // [cfe] 'enum' can't be used as an identifier because it's a keyword.
}
diff --git a/tests/language/label/label8_test.dart b/tests/language/label/label8_test.dart
index 89c6efb6..5d37693 100644
--- a/tests/language/label/label8_test.dart
+++ b/tests/language/label/label8_test.dart
@@ -14,12 +14,12 @@
case 111:
// ^^^^
// [analyzer] COMPILE_TIME_ERROR.UNDEFINED_IDENTIFIER
+// [cfe] 'case' can't be used as an identifier because it's a keyword.
+// ^^^^
+// [analyzer] SYNTACTIC_ERROR.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD
// [cfe] Expected ';' after this.
// ^^^^
// [analyzer] SYNTACTIC_ERROR.EXPECTED_TOKEN
-// [cfe] Expected an identifier, but got 'case'.
-// ^^^^
-// [analyzer] SYNTACTIC_ERROR.MISSING_IDENTIFIER
// [cfe] Getter not found: 'case'.
// ^^^^
// [analyzer] SYNTACTIC_ERROR.MISSING_STATEMENT
diff --git a/tests/language_2/class/keyword_test.dart b/tests/language_2/class/keyword_test.dart
index 5a89f2e..8b07fec 100644
--- a/tests/language_2/class/keyword_test.dart
+++ b/tests/language_2/class/keyword_test.dart
@@ -13,15 +13,15 @@
// [cfe] Expected ';' after this.
// ^^^^^
// [analyzer] COMPILE_TIME_ERROR.UNDEFINED_IDENTIFIER
-// [cfe] Expected an identifier, but got 'class'.
+// [cfe] 'class' can't be used as an identifier because it's a keyword.
// ^^^^^
-// [analyzer] SYNTACTIC_ERROR.MISSING_IDENTIFIER
+// [analyzer] SYNTACTIC_ERROR.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD
// [cfe] Setter not found: 'class'.
print("$class");
// ^^^^^
// [analyzer] COMPILE_TIME_ERROR.UNDEFINED_IDENTIFIER
- // [cfe] Expected an identifier, but got 'class'.
+ // [cfe] 'class' can't be used as an identifier because it's a keyword.
// ^^^^^
- // [analyzer] SYNTACTIC_ERROR.MISSING_IDENTIFIER
+ // [analyzer] SYNTACTIC_ERROR.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD
// [cfe] Getter not found: 'class'.
}
diff --git a/tests/language_2/enum/is_keyword_test.dart b/tests/language_2/enum/is_keyword_test.dart
index 5e7d0b5..4d37239 100644
--- a/tests/language_2/enum/is_keyword_test.dart
+++ b/tests/language_2/enum/is_keyword_test.dart
@@ -8,6 +8,6 @@
main() {
var enum;
// ^^^^
- // [analyzer] SYNTACTIC_ERROR.MISSING_IDENTIFIER
- // [cfe] Expected an identifier, but got 'enum'.
+ // [analyzer] SYNTACTIC_ERROR.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD
+ // [cfe] 'enum' can't be used as an identifier because it's a keyword.
}
diff --git a/tests/language_2/label/label8_test.dart b/tests/language_2/label/label8_test.dart
index a40c1b7..5e71b10 100644
--- a/tests/language_2/label/label8_test.dart
+++ b/tests/language_2/label/label8_test.dart
@@ -14,12 +14,12 @@
case 111:
// ^^^^
// [analyzer] COMPILE_TIME_ERROR.UNDEFINED_IDENTIFIER
+// [cfe] 'case' can't be used as an identifier because it's a keyword.
+// ^^^^
+// [analyzer] SYNTACTIC_ERROR.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD
// [cfe] Expected ';' after this.
// ^^^^
// [analyzer] SYNTACTIC_ERROR.EXPECTED_TOKEN
-// [cfe] Expected an identifier, but got 'case'.
-// ^^^^
-// [analyzer] SYNTACTIC_ERROR.MISSING_IDENTIFIER
// [cfe] Getter not found: 'case'.
// ^^^^
// [analyzer] SYNTACTIC_ERROR.MISSING_STATEMENT
diff --git a/tools/VERSION b/tools/VERSION
index 4121203..4f2e8ca 100644
--- a/tools/VERSION
+++ b/tools/VERSION
@@ -27,5 +27,5 @@
MAJOR 2
MINOR 10
PATCH 0
-PRERELEASE 121
+PRERELEASE 122
PRERELEASE_PATCH 0
\ No newline at end of file