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

Unified Diff: pkg/front_end/lib/src/fasta/fasta_codes_generated.dart

Issue 2973053002: Rename special dart2js error codes. (Closed)
Patch Set: Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/compiler/lib/src/parser/element_listener.dart ('k') | pkg/front_end/messages.yaml » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/front_end/lib/src/fasta/fasta_codes_generated.dart
diff --git a/pkg/front_end/lib/src/fasta/fasta_codes_generated.dart b/pkg/front_end/lib/src/fasta/fasta_codes_generated.dart
index 853a54056e199fdd1070a6745bba31909944037f..9a8d72fae6b176e5ac4ea1b4add3d53465922919 100644
--- a/pkg/front_end/lib/src/fasta/fasta_codes_generated.dart
+++ b/pkg/front_end/lib/src/fasta/fasta_codes_generated.dart
@@ -13,7 +13,7 @@ part of fasta.codes;
const FastaCode<_ExpectedClassBodyToSkip> codeExpectedClassBodyToSkip =
const FastaCode<_ExpectedClassBodyToSkip>("ExpectedClassBodyToSkip",
template: r"Expected a class body, but got '#lexeme'.",
- dart2jsCode: "FASTA_FATAL",
+ dart2jsCode: "*fatal*",
format: _formatExpectedClassBodyToSkip);
typedef FastaMessage _ExpectedClassBodyToSkip(
@@ -32,7 +32,7 @@ FastaMessage _formatExpectedClassBodyToSkip(
const FastaCode<_FunctionTypeDefaultValue> codeFunctionTypeDefaultValue =
const FastaCode<_FunctionTypeDefaultValue>("FunctionTypeDefaultValue",
template: r"Can't have a default value in a function type.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatFunctionTypeDefaultValue);
typedef FastaMessage _FunctionTypeDefaultValue(Uri uri, int charOffset);
@@ -62,7 +62,7 @@ FastaMessage _formatStackOverflow(Uri uri, int charOffset) {
const FastaCode<_AssertExtraneousArgument> codeAssertExtraneousArgument =
const FastaCode<_AssertExtraneousArgument>("AssertExtraneousArgument",
template: r"`assert` can't have more than two arguments.",
- dart2jsCode: "FASTA_FATAL",
+ dart2jsCode: "*fatal*",
format: _formatAssertExtraneousArgument);
typedef FastaMessage _AssertExtraneousArgument(Uri uri, int charOffset);
@@ -77,7 +77,7 @@ FastaMessage _formatAssertExtraneousArgument(Uri uri, int charOffset) {
const FastaCode<_UnexpectedToken> codeUnexpectedToken =
const FastaCode<_UnexpectedToken>("UnexpectedToken",
template: r"Unexpected token '#lexeme'.",
- dart2jsCode: "FASTA_FATAL",
+ dart2jsCode: "*fatal*",
format: _formatUnexpectedToken);
typedef FastaMessage _UnexpectedToken(Uri uri, int charOffset, Token token);
@@ -94,7 +94,7 @@ const FastaCode<_AwaitAsIdentifier> codeAwaitAsIdentifier = const FastaCode<
_AwaitAsIdentifier>("AwaitAsIdentifier",
template:
r"'await' can't be used as an identifier in 'async', 'async*', or 'sync*' methods.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatAwaitAsIdentifier);
typedef FastaMessage _AwaitAsIdentifier(Uri uri, int charOffset);
@@ -111,7 +111,7 @@ FastaMessage _formatAwaitAsIdentifier(Uri uri, int charOffset) {
const FastaCode<_FactoryNotSync> codeFactoryNotSync =
const FastaCode<_FactoryNotSync>("FactoryNotSync",
template: r"Factories can't use 'async', 'async*', or 'sync*'.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatFactoryNotSync);
typedef FastaMessage _FactoryNotSync(Uri uri, int charOffset);
@@ -128,7 +128,7 @@ const FastaCode<_SuperNullAware> codeSuperNullAware =
const FastaCode<_SuperNullAware>("SuperNullAware",
template: r"'super' can't be null.",
tip: r"Try replacing '?.' with '.'",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatSuperNullAware);
typedef FastaMessage _SuperNullAware(Uri uri, int charOffset);
@@ -145,7 +145,7 @@ FastaMessage _formatSuperNullAware(Uri uri, int charOffset) {
const FastaCode<_PrivateNamedParameter> codePrivateNamedParameter =
const FastaCode<_PrivateNamedParameter>("PrivateNamedParameter",
template: r"An optional named parameter can't start with '_'.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatPrivateNamedParameter);
typedef FastaMessage _PrivateNamedParameter(Uri uri, int charOffset);
@@ -161,7 +161,7 @@ FastaMessage _formatPrivateNamedParameter(Uri uri, int charOffset) {
const FastaCode<_YieldNotGenerator> codeYieldNotGenerator =
const FastaCode<_YieldNotGenerator>("YieldNotGenerator",
template: r"'yield' can only be used in 'sync*' or 'async*' methods.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatYieldNotGenerator);
typedef FastaMessage _YieldNotGenerator(Uri uri, int charOffset);
@@ -177,7 +177,7 @@ FastaMessage _formatYieldNotGenerator(Uri uri, int charOffset) {
const FastaCode<_SetterNotSync> codeSetterNotSync =
const FastaCode<_SetterNotSync>("SetterNotSync",
template: r"Setters can't use 'async', 'async*', or 'sync*'.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatSetterNotSync);
typedef FastaMessage _SetterNotSync(Uri uri, int charOffset);
@@ -356,7 +356,7 @@ const FastaCode<_FinalFieldWithoutInitializer>
"FinalFieldWithoutInitializer",
template: r"A 'final' field must be initialized.",
tip: r"Try adding '= <initializer>'.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatFinalFieldWithoutInitializer);
typedef FastaMessage _FinalFieldWithoutInitializer(Uri uri, int charOffset);
@@ -427,7 +427,7 @@ FastaMessage _formatUnterminatedString(Uri uri, int charOffset, String string) {
const FastaCode<_AwaitNotAsync> codeAwaitNotAsync =
const FastaCode<_AwaitNotAsync>("AwaitNotAsync",
template: r"'await' can only be used in 'async' or 'async*' methods.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatAwaitNotAsync);
typedef FastaMessage _AwaitNotAsync(Uri uri, int charOffset);
@@ -513,7 +513,7 @@ FastaMessage _formatUnsupportedPrefixPlus(Uri uri, int charOffset) {
const FastaCode<_ExpectedString> codeExpectedString =
const FastaCode<_ExpectedString>("ExpectedString",
template: r"Expected a String, but got '#lexeme'.",
- dart2jsCode: "FASTA_FATAL",
+ dart2jsCode: "*fatal*",
format: _formatExpectedString);
typedef FastaMessage _ExpectedString(Uri uri, int charOffset, Token token);
@@ -548,7 +548,7 @@ FastaMessage _formatTypeAfterVar(Uri uri, int charOffset) {
const FastaCode<_AbstractNotSync> codeAbstractNotSync =
const FastaCode<_AbstractNotSync>("AbstractNotSync",
template: r"Abstract methods can't use 'async', 'async*', or 'sync*'.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatAbstractNotSync);
typedef FastaMessage _AbstractNotSync(Uri uri, int charOffset);
@@ -564,7 +564,7 @@ FastaMessage _formatAbstractNotSync(Uri uri, int charOffset) {
const FastaCode<_ExpectedDeclaration> codeExpectedDeclaration =
const FastaCode<_ExpectedDeclaration>("ExpectedDeclaration",
template: r"Expected a declaration, but got '#lexeme'.",
- dart2jsCode: "FASTA_FATAL",
+ dart2jsCode: "*fatal*",
format: _formatExpectedDeclaration);
typedef FastaMessage _ExpectedDeclaration(Uri uri, int charOffset, Token token);
@@ -641,7 +641,7 @@ const FastaCode<_GetterWithFormals> codeGetterWithFormals =
const FastaCode<_GetterWithFormals>("GetterWithFormals",
template: r"A getter can't have formal parameters.",
tip: r"Try removing '(...)'.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatGetterWithFormals);
typedef FastaMessage _GetterWithFormals(Uri uri, int charOffset);
@@ -660,7 +660,7 @@ const FastaCode<_NoFormals> codeNoFormals = const FastaCode<_NoFormals>(
template: r"A function should have formal parameters.",
tip:
r"Try adding '()' after '#lexeme', or add 'get' before '#lexeme' to declare a getter.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatNoFormals);
typedef FastaMessage _NoFormals(Uri uri, int charOffset, Token token);
@@ -713,7 +713,7 @@ const FastaCode<_CatchSyntax> codeCatchSyntax = const FastaCode<_CatchSyntax>(
r"'catch' must be followed by '(identifier)' or '(identifier, identifier)'.",
tip:
r"No types are needed, the first is given by 'on', the second is always 'StackTrace'.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatCatchSyntax);
typedef FastaMessage _CatchSyntax(Uri uri, int charOffset);
@@ -732,7 +732,7 @@ FastaMessage _formatCatchSyntax(Uri uri, int charOffset) {
const FastaCode<_ExpectedClassBody> codeExpectedClassBody =
const FastaCode<_ExpectedClassBody>("ExpectedClassBody",
template: r"Expected a class body, but got '#lexeme'.",
- dart2jsCode: "FASTA_FATAL",
+ dart2jsCode: "*fatal*",
format: _formatExpectedClassBody);
typedef FastaMessage _ExpectedClassBody(Uri uri, int charOffset, Token token);
@@ -749,7 +749,7 @@ FastaMessage _formatExpectedClassBody(Uri uri, int charOffset, Token token) {
const FastaCode<_ExpectedExpression> codeExpectedExpression =
const FastaCode<_ExpectedExpression>("ExpectedExpression",
template: r"Expected an expression, but got '#lexeme'.",
- dart2jsCode: "FASTA_FATAL",
+ dart2jsCode: "*fatal*",
format: _formatExpectedExpression);
typedef FastaMessage _ExpectedExpression(Uri uri, int charOffset, Token token);
@@ -788,7 +788,7 @@ FastaMessage _formatInvalidAwaitFor(Uri uri, int charOffset) {
const FastaCode<_ExpectedType> codeExpectedType =
const FastaCode<_ExpectedType>("ExpectedType",
template: r"Expected a type, but got '#lexeme'.",
- dart2jsCode: "FASTA_FATAL",
+ dart2jsCode: "*fatal*",
format: _formatExpectedType);
typedef FastaMessage _ExpectedType(Uri uri, int charOffset, Token token);
@@ -841,7 +841,7 @@ const FastaCode<_ConstFieldWithoutInitializer>
"ConstFieldWithoutInitializer",
template: r"A 'const' field must be initialized.",
tip: r"Try adding '= <initializer>'.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatConstFieldWithoutInitializer);
typedef FastaMessage _ConstFieldWithoutInitializer(Uri uri, int charOffset);
@@ -859,7 +859,7 @@ const FastaCode<_AwaitForNotAsync> codeAwaitForNotAsync = const FastaCode<
_AwaitForNotAsync>("AwaitForNotAsync",
template:
r"Asynchronous for-loop can only be used in 'async' or 'async*' methods.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatAwaitForNotAsync);
typedef FastaMessage _AwaitForNotAsync(Uri uri, int charOffset);
@@ -875,7 +875,7 @@ FastaMessage _formatAwaitForNotAsync(Uri uri, int charOffset) {
// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
const FastaCode<_Encoding> codeEncoding = const FastaCode<_Encoding>("Encoding",
template: r"Unable to decode bytes as UTF-8.",
- dart2jsCode: "FASTA_FATAL",
+ dart2jsCode: "*fatal*",
format: _formatEncoding);
typedef FastaMessage _Encoding(Uri uri, int charOffset);
@@ -910,7 +910,7 @@ const FastaCode<_YieldAsIdentifier> codeYieldAsIdentifier = const FastaCode<
_YieldAsIdentifier>("YieldAsIdentifier",
template:
r"'yield' can't be used as an identifier in 'async', 'async*', or 'sync*' methods.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatYieldAsIdentifier);
typedef FastaMessage _YieldAsIdentifier(Uri uri, int charOffset);
@@ -927,7 +927,7 @@ FastaMessage _formatYieldAsIdentifier(Uri uri, int charOffset) {
const FastaCode<_AssertAsExpression> codeAssertAsExpression =
const FastaCode<_AssertAsExpression>("AssertAsExpression",
template: r"`assert` can't be used as an expression.",
- dart2jsCode: "FASTA_FATAL",
+ dart2jsCode: "*fatal*",
format: _formatAssertAsExpression);
typedef FastaMessage _AssertAsExpression(Uri uri, int charOffset);
@@ -943,7 +943,7 @@ const FastaCode<_OnlyTry> codeOnlyTry = const FastaCode<_OnlyTry>("OnlyTry",
template:
r"Try block should be followed by 'on', 'catch', or 'finally' block.",
tip: r"Did you forget to add a 'finally' block?",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatOnlyTry);
typedef FastaMessage _OnlyTry(Uri uri, int charOffset);
@@ -982,7 +982,7 @@ FastaMessage _formatInvalidInlineFunctionType(Uri uri, int charOffset) {
const FastaCode<_MetadataTypeArguments> codeMetadataTypeArguments =
const FastaCode<_MetadataTypeArguments>("MetadataTypeArguments",
template: r"An annotation (metadata) can't use type arguments.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatMetadataTypeArguments);
typedef FastaMessage _MetadataTypeArguments(Uri uri, int charOffset);
@@ -1072,7 +1072,7 @@ FastaMessage _formatBuiltInIdentifierAsType(
const FastaCode<_GeneratorReturnsValue> codeGeneratorReturnsValue =
const FastaCode<_GeneratorReturnsValue>("GeneratorReturnsValue",
template: r"'sync*' and 'async*' can't return a value.",
- dart2jsCode: "FASTA_IGNORED",
+ dart2jsCode: "*ignored*",
format: _formatGeneratorReturnsValue);
typedef FastaMessage _GeneratorReturnsValue(Uri uri, int charOffset);
« no previous file with comments | « pkg/compiler/lib/src/parser/element_listener.dart ('k') | pkg/front_end/messages.yaml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698