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

Side by Side Diff: pkg/analyzer/lib/src/generated/parser.dart

Issue 214593008: Rollback pkg/analyzer that breaks code_transformers (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 9 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 // This code was auto-generated, is not intended to be edited, and is subject to 5 // This code was auto-generated, is not intended to be edited, and is subject to
6 // significant change. Please see the README file for more information. 6 // significant change. Please see the README file for more information.
7 7
8 library engine.parser; 8 library engine.parser;
9 9
10 import 'java_core.dart'; 10 import 'java_core.dart';
11 import 'java_engine.dart'; 11 import 'java_engine.dart';
12 import 'instrumentation.dart'; 12 import 'instrumentation.dart';
13 import 'error.dart'; 13 import 'error.dart';
14 import 'source.dart'; 14 import 'source.dart';
15 import 'scanner.dart'; 15 import 'scanner.dart';
16 import 'ast.dart'; 16 import 'ast.dart';
17 import 'utilities_dart.dart'; 17 import 'utilities_dart.dart';
18 import 'engine.dart' show AnalysisEngine; 18 import 'engine.dart' show AnalysisEngine;
19 import 'utilities_collection.dart' show TokenMap; 19 import 'utilities_collection.dart' show TokenMap;
20 20
21 /** 21 /**
22 * Instances of the class `CommentAndMetadata` implement a simple data-holder fo r a method 22 * Instances of the class `CommentAndMetadata` implement a simple data-holder fo r a method
23 * that needs to return multiple values. 23 * that needs to return multiple values.
24 */ 24 */
25 class CommentAndMetadata { 25 class CommentAndMetadata {
26 /** 26 /**
27 * The documentation comment that was parsed, or `null` if none was given. 27 * The documentation comment that was parsed, or `null` if none was given.
28 */ 28 */
29 final Comment comment; 29 Comment comment;
30 30
31 /** 31 /**
32 * The metadata that was parsed. 32 * The metadata that was parsed.
33 */ 33 */
34 final List<Annotation> metadata; 34 List<Annotation> metadata;
35 35
36 /** 36 /**
37 * Initialize a newly created holder with the given data. 37 * Initialize a newly created holder with the given data.
38 * 38 *
39 * @param comment the documentation comment that was parsed 39 * @param comment the documentation comment that was parsed
40 * @param metadata the metadata that was parsed 40 * @param metadata the metadata that was parsed
41 */ 41 */
42 CommentAndMetadata(this.comment, this.metadata); 42 CommentAndMetadata(Comment comment, List<Annotation> metadata) {
43 this.comment = comment;
44 this.metadata = metadata;
45 }
43 } 46 }
44 47
45 /** 48 /**
46 * Instances of the class `FinalConstVarOrType` implement a simple data-holder f or a method 49 * Instances of the class `FinalConstVarOrType` implement a simple data-holder f or a method
47 * that needs to return multiple values. 50 * that needs to return multiple values.
48 */ 51 */
49 class FinalConstVarOrType { 52 class FinalConstVarOrType {
50 /** 53 /**
51 * The 'final', 'const' or 'var' keyword, or `null` if none was given. 54 * The 'final', 'const' or 'var' keyword, or `null` if none was given.
52 */ 55 */
53 final Token keyword; 56 Token keyword;
54 57
55 /** 58 /**
56 * The type, of `null` if no type was specified. 59 * The type, of `null` if no type was specified.
57 */ 60 */
58 final TypeName type; 61 TypeName type;
59 62
60 /** 63 /**
61 * Initialize a newly created holder with the given data. 64 * Initialize a newly created holder with the given data.
62 * 65 *
63 * @param keyword the 'final', 'const' or 'var' keyword 66 * @param keyword the 'final', 'const' or 'var' keyword
64 * @param type the type 67 * @param type the type
65 */ 68 */
66 FinalConstVarOrType(this.keyword, this.type); 69 FinalConstVarOrType(Token keyword, TypeName type) {
70 this.keyword = keyword;
71 this.type = type;
72 }
67 } 73 }
68 74
69 /** 75 /**
70 * Instances of the class `Modifiers` implement a simple data-holder for a metho d that needs 76 * Instances of the class `Modifiers` implement a simple data-holder for a metho d that needs
71 * to return multiple values. 77 * to return multiple values.
72 */ 78 */
73 class Modifiers { 79 class Modifiers {
74 /** 80 /**
75 * The token representing the keyword 'abstract', or `null` if the keyword was not found. 81 * The token representing the keyword 'abstract', or `null` if the keyword was not found.
76 */ 82 */
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 * Instances of the class `IncrementalParseDispatcher` implement a dispatcher th at will invoke 150 * Instances of the class `IncrementalParseDispatcher` implement a dispatcher th at will invoke
145 * the right parse method when re-parsing a specified child of the visited node. All of the methods 151 * the right parse method when re-parsing a specified child of the visited node. All of the methods
146 * in this class assume that the parser is positioned to parse the replacement f or the node. All of 152 * in this class assume that the parser is positioned to parse the replacement f or the node. All of
147 * the methods will throw an [IncrementalParseException] if the node could not b e parsed for 153 * the methods will throw an [IncrementalParseException] if the node could not b e parsed for
148 * some reason. 154 * some reason.
149 */ 155 */
150 class IncrementalParseDispatcher implements AstVisitor<AstNode> { 156 class IncrementalParseDispatcher implements AstVisitor<AstNode> {
151 /** 157 /**
152 * The parser used to parse the replacement for the node. 158 * The parser used to parse the replacement for the node.
153 */ 159 */
154 final Parser _parser; 160 Parser _parser;
155 161
156 /** 162 /**
157 * The node that is to be replaced. 163 * The node that is to be replaced.
158 */ 164 */
159 final AstNode _oldNode; 165 AstNode _oldNode;
160 166
161 /** 167 /**
162 * Initialize a newly created dispatcher to parse a single node that will repl ace the given node. 168 * Initialize a newly created dispatcher to parse a single node that will repl ace the given node.
163 * 169 *
164 * @param parser the parser used to parse the replacement for the node 170 * @param parser the parser used to parse the replacement for the node
165 * @param oldNode the node that is to be replaced 171 * @param oldNode the node that is to be replaced
166 */ 172 */
167 IncrementalParseDispatcher(this._parser, this._oldNode); 173 IncrementalParseDispatcher(Parser parser, AstNode oldNode) {
174 this._parser = parser;
175 this._oldNode = oldNode;
176 }
168 177
169 @override 178 @override
170 AstNode visitAdjacentStrings(AdjacentStrings node) { 179 AstNode visitAdjacentStrings(AdjacentStrings node) {
171 if (node.strings.contains(_oldNode)) { 180 if (node.strings.contains(_oldNode)) {
172 return _parser.parseStringLiteral(); 181 return _parser.parseStringLiteral();
173 } 182 }
174 return _notAChild(node); 183 return _notAChild(node);
175 } 184 }
176 185
177 @override 186 @override
(...skipping 1055 matching lines...) Expand 10 before | Expand all | Expand 10 after
1233 } 1242 }
1234 1243
1235 /** 1244 /**
1236 * Instances of the class `IncrementalParser` re-parse a single AST structure wi thin a larger 1245 * Instances of the class `IncrementalParser` re-parse a single AST structure wi thin a larger
1237 * AST structure. 1246 * AST structure.
1238 */ 1247 */
1239 class IncrementalParser { 1248 class IncrementalParser {
1240 /** 1249 /**
1241 * The source being parsed. 1250 * The source being parsed.
1242 */ 1251 */
1243 final Source _source; 1252 Source _source;
1244 1253
1245 /** 1254 /**
1246 * A map from old tokens to new tokens used during the cloning process. 1255 * A map from old tokens to new tokens used during the cloning process.
1247 */ 1256 */
1248 final TokenMap _tokenMap; 1257 TokenMap _tokenMap;
1249 1258
1250 /** 1259 /**
1251 * The error listener that will be informed of any errors that are found durin g the parse. 1260 * The error listener that will be informed of any errors that are found durin g the parse.
1252 */ 1261 */
1253 final AnalysisErrorListener _errorListener; 1262 AnalysisErrorListener _errorListener;
1254 1263
1255 /** 1264 /**
1256 * The node in the AST structure that contains the revised content. 1265 * The node in the AST structure that contains the revised content.
1257 */ 1266 */
1258 AstNode _updatedNode; 1267 AstNode _updatedNode;
1259 1268
1260 /** 1269 /**
1261 * Initialize a newly created incremental parser to parse a portion of the con tent of the given 1270 * Initialize a newly created incremental parser to parse a portion of the con tent of the given
1262 * source. 1271 * source.
1263 * 1272 *
1264 * @param source the source being parsed 1273 * @param source the source being parsed
1265 * @param tokenMap a map from old tokens to new tokens used during the cloning process 1274 * @param tokenMap a map from old tokens to new tokens used during the cloning process
1266 * @param errorListener the error listener that will be informed of any errors that are found 1275 * @param errorListener the error listener that will be informed of any errors that are found
1267 * during the parse 1276 * during the parse
1268 */ 1277 */
1269 IncrementalParser(this._source, this._tokenMap, this._errorListener); 1278 IncrementalParser(Source source, TokenMap tokenMap, AnalysisErrorListener erro rListener) {
1279 this._source = source;
1280 this._tokenMap = tokenMap;
1281 this._errorListener = errorListener;
1282 }
1270 1283
1271 /** 1284 /**
1272 * Return the node in the AST structure that contains the revised content. 1285 * Return the node in the AST structure that contains the revised content.
1273 * 1286 *
1274 * @return the updated node 1287 * @return the updated node
1275 */ 1288 */
1276 AstNode get updatedNode => _updatedNode; 1289 AstNode get updatedNode => _updatedNode;
1277 1290
1278 /** 1291 /**
1279 * Given a range of tokens that were re-scanned, re-parse the minimum number o f tokens to produce 1292 * Given a range of tokens that were re-scanned, re-parse the minimum number o f tokens to produce
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
1419 InsufficientContextException.con2(Exception cause) : super.con2(cause); 1432 InsufficientContextException.con2(Exception cause) : super.con2(cause);
1420 } 1433 }
1421 1434
1422 /** 1435 /**
1423 * Instances of the class `Parser` are used to parse tokens into an AST structur e. 1436 * Instances of the class `Parser` are used to parse tokens into an AST structur e.
1424 */ 1437 */
1425 class Parser { 1438 class Parser {
1426 /** 1439 /**
1427 * The source being parsed. 1440 * The source being parsed.
1428 */ 1441 */
1429 final Source _source; 1442 Source _source;
1430 1443
1431 /** 1444 /**
1432 * The error listener that will be informed of any errors that are found durin g the parse. 1445 * The error listener that will be informed of any errors that are found durin g the parse.
1433 */ 1446 */
1434 final AnalysisErrorListener _errorListener; 1447 AnalysisErrorListener _errorListener;
1435 1448
1436 /** 1449 /**
1437 * An [errorListener] lock, if more than `0`, then errors are not reported. 1450 * An [errorListener] lock, if more than `0`, then errors are not reported.
1438 */ 1451 */
1439 int _errorListenerLock = 0; 1452 int _errorListenerLock = 0;
1440 1453
1441 /** 1454 /**
1442 * A flag indicating whether parser is to parse function bodies. 1455 * A flag indicating whether parser is to parse function bodies.
1443 */ 1456 */
1444 bool _parseFunctionBodies = true; 1457 bool _parseFunctionBodies = true;
(...skipping 23 matching lines...) Expand all
1468 1481
1469 static String _SHOW = "show"; 1482 static String _SHOW = "show";
1470 1483
1471 /** 1484 /**
1472 * Initialize a newly created parser. 1485 * Initialize a newly created parser.
1473 * 1486 *
1474 * @param source the source being parsed 1487 * @param source the source being parsed
1475 * @param errorListener the error listener that will be informed of any errors that are found 1488 * @param errorListener the error listener that will be informed of any errors that are found
1476 * during the parse 1489 * during the parse
1477 */ 1490 */
1478 Parser(this._source, this._errorListener); 1491 Parser(Source source, AnalysisErrorListener errorListener) {
1492 this._source = source;
1493 this._errorListener = errorListener;
1494 }
1479 1495
1480 /** 1496 /**
1481 * Parse a compilation unit, starting with the given token. 1497 * Parse a compilation unit, starting with the given token.
1482 * 1498 *
1483 * @param token the first token of the compilation unit 1499 * @param token the first token of the compilation unit
1484 * @return the compilation unit that was parsed 1500 * @return the compilation unit that was parsed
1485 */ 1501 */
1486 CompilationUnit parseCompilationUnit(Token token) { 1502 CompilationUnit parseCompilationUnit(Token token) {
1487 InstrumentationBuilder instrumentation = Instrumentation.builder2("dart.engi ne.Parser.parseCompilationUnit"); 1503 InstrumentationBuilder instrumentation = Instrumentation.builder2("dart.engi ne.Parser.parseCompilationUnit");
1488 try { 1504 try {
(...skipping 5839 matching lines...) Expand 10 before | Expand all | Expand 10 after
7328 int get length => 0; 7344 int get length => 0;
7329 } 7345 }
7330 7346
7331 /** 7347 /**
7332 * The enumeration `ParserErrorCode` defines the error codes used for errors det ected by the 7348 * The enumeration `ParserErrorCode` defines the error codes used for errors det ected by the
7333 * parser. The convention for this class is for the name of the error code to in dicate the problem 7349 * parser. The convention for this class is for the name of the error code to in dicate the problem
7334 * that caused the error to be generated and for the error message to explain wh at is wrong and, 7350 * that caused the error to be generated and for the error message to explain wh at is wrong and,
7335 * when appropriate, how the problem can be corrected. 7351 * when appropriate, how the problem can be corrected.
7336 */ 7352 */
7337 class ParserErrorCode extends Enum<ParserErrorCode> implements ErrorCode { 7353 class ParserErrorCode extends Enum<ParserErrorCode> implements ErrorCode {
7338 static const ParserErrorCode ABSTRACT_CLASS_MEMBER = const ParserErrorCode.con 3('ABSTRACT_CLASS_MEMBER', 0, "Members of classes cannot be declared to be 'abst ract'"); 7354 static final ParserErrorCode ABSTRACT_CLASS_MEMBER = new ParserErrorCode.con3( 'ABSTRACT_CLASS_MEMBER', 0, "Members of classes cannot be declared to be 'abstra ct'");
7339 7355
7340 static const ParserErrorCode ABSTRACT_STATIC_METHOD = const ParserErrorCode.co n3('ABSTRACT_STATIC_METHOD', 1, "Static methods cannot be declared to be 'abstra ct'"); 7356 static final ParserErrorCode ABSTRACT_STATIC_METHOD = new ParserErrorCode.con3 ('ABSTRACT_STATIC_METHOD', 1, "Static methods cannot be declared to be 'abstract '");
7341 7357
7342 static const ParserErrorCode ABSTRACT_TOP_LEVEL_FUNCTION = const ParserErrorCo de.con3('ABSTRACT_TOP_LEVEL_FUNCTION', 2, "Top-level functions cannot be declare d to be 'abstract'"); 7358 static final ParserErrorCode ABSTRACT_TOP_LEVEL_FUNCTION = new ParserErrorCode .con3('ABSTRACT_TOP_LEVEL_FUNCTION', 2, "Top-level functions cannot be declared to be 'abstract'");
7343 7359
7344 static const ParserErrorCode ABSTRACT_TOP_LEVEL_VARIABLE = const ParserErrorCo de.con3('ABSTRACT_TOP_LEVEL_VARIABLE', 3, "Top-level variables cannot be declare d to be 'abstract'"); 7360 static final ParserErrorCode ABSTRACT_TOP_LEVEL_VARIABLE = new ParserErrorCode .con3('ABSTRACT_TOP_LEVEL_VARIABLE', 3, "Top-level variables cannot be declared to be 'abstract'");
7345 7361
7346 static const ParserErrorCode ABSTRACT_TYPEDEF = const ParserErrorCode.con3('AB STRACT_TYPEDEF', 4, "Type aliases cannot be declared to be 'abstract'"); 7362 static final ParserErrorCode ABSTRACT_TYPEDEF = new ParserErrorCode.con3('ABST RACT_TYPEDEF', 4, "Type aliases cannot be declared to be 'abstract'");
7347 7363
7348 static const ParserErrorCode ASSERT_DOES_NOT_TAKE_ASSIGNMENT = const ParserErr orCode.con3('ASSERT_DOES_NOT_TAKE_ASSIGNMENT', 5, "Assert cannot be called on an assignment"); 7364 static final ParserErrorCode ASSERT_DOES_NOT_TAKE_ASSIGNMENT = new ParserError Code.con3('ASSERT_DOES_NOT_TAKE_ASSIGNMENT', 5, "Assert cannot be called on an a ssignment");
7349 7365
7350 static const ParserErrorCode ASSERT_DOES_NOT_TAKE_CASCADE = const ParserErrorC ode.con3('ASSERT_DOES_NOT_TAKE_CASCADE', 6, "Assert cannot be called on cascade" ); 7366 static final ParserErrorCode ASSERT_DOES_NOT_TAKE_CASCADE = new ParserErrorCod e.con3('ASSERT_DOES_NOT_TAKE_CASCADE', 6, "Assert cannot be called on cascade");
7351 7367
7352 static const ParserErrorCode ASSERT_DOES_NOT_TAKE_THROW = const ParserErrorCod e.con3('ASSERT_DOES_NOT_TAKE_THROW', 7, "Assert cannot be called on throws"); 7368 static final ParserErrorCode ASSERT_DOES_NOT_TAKE_THROW = new ParserErrorCode. con3('ASSERT_DOES_NOT_TAKE_THROW', 7, "Assert cannot be called on throws");
7353 7369
7354 static const ParserErrorCode ASSERT_DOES_NOT_TAKE_RETHROW = const ParserErrorC ode.con3('ASSERT_DOES_NOT_TAKE_RETHROW', 8, "Assert cannot be called on rethrows "); 7370 static final ParserErrorCode ASSERT_DOES_NOT_TAKE_RETHROW = new ParserErrorCod e.con3('ASSERT_DOES_NOT_TAKE_RETHROW', 8, "Assert cannot be called on rethrows") ;
7355 7371
7356 static const ParserErrorCode BREAK_OUTSIDE_OF_LOOP = const ParserErrorCode.con 3('BREAK_OUTSIDE_OF_LOOP', 9, "A break statement cannot be used outside of a loo p or switch statement"); 7372 static final ParserErrorCode BREAK_OUTSIDE_OF_LOOP = new ParserErrorCode.con3( 'BREAK_OUTSIDE_OF_LOOP', 9, "A break statement cannot be used outside of a loop or switch statement");
7357 7373
7358 static const ParserErrorCode CONST_AND_FINAL = const ParserErrorCode.con3('CON ST_AND_FINAL', 10, "Members cannot be declared to be both 'const' and 'final'"); 7374 static final ParserErrorCode CONST_AND_FINAL = new ParserErrorCode.con3('CONST _AND_FINAL', 10, "Members cannot be declared to be both 'const' and 'final'");
7359 7375
7360 static const ParserErrorCode CONST_AND_VAR = const ParserErrorCode.con3('CONST _AND_VAR', 11, "Members cannot be declared to be both 'const' and 'var'"); 7376 static final ParserErrorCode CONST_AND_VAR = new ParserErrorCode.con3('CONST_A ND_VAR', 11, "Members cannot be declared to be both 'const' and 'var'");
7361 7377
7362 static const ParserErrorCode CONST_CLASS = const ParserErrorCode.con3('CONST_C LASS', 12, "Classes cannot be declared to be 'const'"); 7378 static final ParserErrorCode CONST_CLASS = new ParserErrorCode.con3('CONST_CLA SS', 12, "Classes cannot be declared to be 'const'");
7363 7379
7364 static const ParserErrorCode CONST_CONSTRUCTOR_WITH_BODY = const ParserErrorCo de.con3('CONST_CONSTRUCTOR_WITH_BODY', 13, "'const' constructors cannot have a b ody"); 7380 static final ParserErrorCode CONST_CONSTRUCTOR_WITH_BODY = new ParserErrorCode .con3('CONST_CONSTRUCTOR_WITH_BODY', 13, "'const' constructors cannot have a bod y");
7365 7381
7366 static const ParserErrorCode CONST_FACTORY = const ParserErrorCode.con3('CONST _FACTORY', 14, "Only redirecting factory constructors can be declared to be 'con st'"); 7382 static final ParserErrorCode CONST_FACTORY = new ParserErrorCode.con3('CONST_F ACTORY', 14, "Only redirecting factory constructors can be declared to be 'const '");
7367 7383
7368 static const ParserErrorCode CONST_METHOD = const ParserErrorCode.con3('CONST_ METHOD', 15, "Getters, setters and methods cannot be declared to be 'const'"); 7384 static final ParserErrorCode CONST_METHOD = new ParserErrorCode.con3('CONST_ME THOD', 15, "Getters, setters and methods cannot be declared to be 'const'");
7369 7385
7370 static const ParserErrorCode CONST_TYPEDEF = const ParserErrorCode.con3('CONST _TYPEDEF', 16, "Type aliases cannot be declared to be 'const'"); 7386 static final ParserErrorCode CONST_TYPEDEF = new ParserErrorCode.con3('CONST_T YPEDEF', 16, "Type aliases cannot be declared to be 'const'");
7371 7387
7372 static const ParserErrorCode CONSTRUCTOR_WITH_RETURN_TYPE = const ParserErrorC ode.con3('CONSTRUCTOR_WITH_RETURN_TYPE', 17, "Constructors cannot have a return type"); 7388 static final ParserErrorCode CONSTRUCTOR_WITH_RETURN_TYPE = new ParserErrorCod e.con3('CONSTRUCTOR_WITH_RETURN_TYPE', 17, "Constructors cannot have a return ty pe");
7373 7389
7374 static const ParserErrorCode CONTINUE_OUTSIDE_OF_LOOP = const ParserErrorCode. con3('CONTINUE_OUTSIDE_OF_LOOP', 18, "A continue statement cannot be used outsid e of a loop or switch statement"); 7390 static final ParserErrorCode CONTINUE_OUTSIDE_OF_LOOP = new ParserErrorCode.co n3('CONTINUE_OUTSIDE_OF_LOOP', 18, "A continue statement cannot be used outside of a loop or switch statement");
7375 7391
7376 static const ParserErrorCode CONTINUE_WITHOUT_LABEL_IN_CASE = const ParserErro rCode.con3('CONTINUE_WITHOUT_LABEL_IN_CASE', 19, "A continue statement in a swit ch statement must have a label as a target"); 7392 static final ParserErrorCode CONTINUE_WITHOUT_LABEL_IN_CASE = new ParserErrorC ode.con3('CONTINUE_WITHOUT_LABEL_IN_CASE', 19, "A continue statement in a switch statement must have a label as a target");
7377 7393
7378 static const ParserErrorCode DEPRECATED_ARGUMENT_DEFINITION_TEST = const Parse rErrorCode.con3('DEPRECATED_ARGUMENT_DEFINITION_TEST', 20, "The argument definit ion test ('?' operator) has been deprecated"); 7394 static final ParserErrorCode DEPRECATED_ARGUMENT_DEFINITION_TEST = new ParserE rrorCode.con3('DEPRECATED_ARGUMENT_DEFINITION_TEST', 20, "The argument definitio n test ('?' operator) has been deprecated");
7379 7395
7380 static const ParserErrorCode DEPRECATED_CLASS_TYPE_ALIAS = const ParserErrorCo de.con3('DEPRECATED_CLASS_TYPE_ALIAS', 21, "The 'typedef' mixin application was replaced with 'class'"); 7396 static final ParserErrorCode DEPRECATED_CLASS_TYPE_ALIAS = new ParserErrorCode .con3('DEPRECATED_CLASS_TYPE_ALIAS', 21, "The 'typedef' mixin application was re placed with 'class'");
7381 7397
7382 static const ParserErrorCode DIRECTIVE_AFTER_DECLARATION = const ParserErrorCo de.con3('DIRECTIVE_AFTER_DECLARATION', 22, "Directives must appear before any de clarations"); 7398 static final ParserErrorCode DIRECTIVE_AFTER_DECLARATION = new ParserErrorCode .con3('DIRECTIVE_AFTER_DECLARATION', 22, "Directives must appear before any decl arations");
7383 7399
7384 static const ParserErrorCode DUPLICATE_LABEL_IN_SWITCH_STATEMENT = const Parse rErrorCode.con3('DUPLICATE_LABEL_IN_SWITCH_STATEMENT', 23, "The label %s was alr eady used in this switch statement"); 7400 static final ParserErrorCode DUPLICATE_LABEL_IN_SWITCH_STATEMENT = new ParserE rrorCode.con3('DUPLICATE_LABEL_IN_SWITCH_STATEMENT', 23, "The label %s was alrea dy used in this switch statement");
7385 7401
7386 static const ParserErrorCode DUPLICATED_MODIFIER = const ParserErrorCode.con3( 'DUPLICATED_MODIFIER', 24, "The modifier '%s' was already specified."); 7402 static final ParserErrorCode DUPLICATED_MODIFIER = new ParserErrorCode.con3('D UPLICATED_MODIFIER', 24, "The modifier '%s' was already specified.");
7387 7403
7388 static const ParserErrorCode EQUALITY_CANNOT_BE_EQUALITY_OPERAND = const Parse rErrorCode.con3('EQUALITY_CANNOT_BE_EQUALITY_OPERAND', 25, "Equality expression cannot be operand of another equality expression."); 7404 static final ParserErrorCode EQUALITY_CANNOT_BE_EQUALITY_OPERAND = new ParserE rrorCode.con3('EQUALITY_CANNOT_BE_EQUALITY_OPERAND', 25, "Equality expression ca nnot be operand of another equality expression.");
7389 7405
7390 static const ParserErrorCode EXPECTED_CASE_OR_DEFAULT = const ParserErrorCode. con3('EXPECTED_CASE_OR_DEFAULT', 26, "Expected 'case' or 'default'"); 7406 static final ParserErrorCode EXPECTED_CASE_OR_DEFAULT = new ParserErrorCode.co n3('EXPECTED_CASE_OR_DEFAULT', 26, "Expected 'case' or 'default'");
7391 7407
7392 static const ParserErrorCode EXPECTED_CLASS_MEMBER = const ParserErrorCode.con 3('EXPECTED_CLASS_MEMBER', 27, "Expected a class member"); 7408 static final ParserErrorCode EXPECTED_CLASS_MEMBER = new ParserErrorCode.con3( 'EXPECTED_CLASS_MEMBER', 27, "Expected a class member");
7393 7409
7394 static const ParserErrorCode EXPECTED_EXECUTABLE = const ParserErrorCode.con3( 'EXPECTED_EXECUTABLE', 28, "Expected a method, getter, setter or operator declar ation"); 7410 static final ParserErrorCode EXPECTED_EXECUTABLE = new ParserErrorCode.con3('E XPECTED_EXECUTABLE', 28, "Expected a method, getter, setter or operator declarat ion");
7395 7411
7396 static const ParserErrorCode EXPECTED_LIST_OR_MAP_LITERAL = const ParserErrorC ode.con3('EXPECTED_LIST_OR_MAP_LITERAL', 29, "Expected a list or map literal"); 7412 static final ParserErrorCode EXPECTED_LIST_OR_MAP_LITERAL = new ParserErrorCod e.con3('EXPECTED_LIST_OR_MAP_LITERAL', 29, "Expected a list or map literal");
7397 7413
7398 static const ParserErrorCode EXPECTED_STRING_LITERAL = const ParserErrorCode.c on3('EXPECTED_STRING_LITERAL', 30, "Expected a string literal"); 7414 static final ParserErrorCode EXPECTED_STRING_LITERAL = new ParserErrorCode.con 3('EXPECTED_STRING_LITERAL', 30, "Expected a string literal");
7399 7415
7400 static const ParserErrorCode EXPECTED_TOKEN = const ParserErrorCode.con3('EXPE CTED_TOKEN', 31, "Expected to find '%s'"); 7416 static final ParserErrorCode EXPECTED_TOKEN = new ParserErrorCode.con3('EXPECT ED_TOKEN', 31, "Expected to find '%s'");
7401 7417
7402 static const ParserErrorCode EXPECTED_TYPE_NAME = const ParserErrorCode.con3(' EXPECTED_TYPE_NAME', 32, "Expected a type name"); 7418 static final ParserErrorCode EXPECTED_TYPE_NAME = new ParserErrorCode.con3('EX PECTED_TYPE_NAME', 32, "Expected a type name");
7403 7419
7404 static const ParserErrorCode EXPORT_DIRECTIVE_AFTER_PART_DIRECTIVE = const Par serErrorCode.con3('EXPORT_DIRECTIVE_AFTER_PART_DIRECTIVE', 33, "Export directive s must preceed part directives"); 7420 static final ParserErrorCode EXPORT_DIRECTIVE_AFTER_PART_DIRECTIVE = new Parse rErrorCode.con3('EXPORT_DIRECTIVE_AFTER_PART_DIRECTIVE', 33, "Export directives must preceed part directives");
7405 7421
7406 static const ParserErrorCode EXTERNAL_AFTER_CONST = const ParserErrorCode.con3 ('EXTERNAL_AFTER_CONST', 34, "The modifier 'external' should be before the modif ier 'const'"); 7422 static final ParserErrorCode EXTERNAL_AFTER_CONST = new ParserErrorCode.con3(' EXTERNAL_AFTER_CONST', 34, "The modifier 'external' should be before the modifie r 'const'");
7407 7423
7408 static const ParserErrorCode EXTERNAL_AFTER_FACTORY = const ParserErrorCode.co n3('EXTERNAL_AFTER_FACTORY', 35, "The modifier 'external' should be before the m odifier 'factory'"); 7424 static final ParserErrorCode EXTERNAL_AFTER_FACTORY = new ParserErrorCode.con3 ('EXTERNAL_AFTER_FACTORY', 35, "The modifier 'external' should be before the mod ifier 'factory'");
7409 7425
7410 static const ParserErrorCode EXTERNAL_AFTER_STATIC = const ParserErrorCode.con 3('EXTERNAL_AFTER_STATIC', 36, "The modifier 'external' should be before the mod ifier 'static'"); 7426 static final ParserErrorCode EXTERNAL_AFTER_STATIC = new ParserErrorCode.con3( 'EXTERNAL_AFTER_STATIC', 36, "The modifier 'external' should be before the modif ier 'static'");
7411 7427
7412 static const ParserErrorCode EXTERNAL_CLASS = const ParserErrorCode.con3('EXTE RNAL_CLASS', 37, "Classes cannot be declared to be 'external'"); 7428 static final ParserErrorCode EXTERNAL_CLASS = new ParserErrorCode.con3('EXTERN AL_CLASS', 37, "Classes cannot be declared to be 'external'");
7413 7429
7414 static const ParserErrorCode EXTERNAL_CONSTRUCTOR_WITH_BODY = const ParserErro rCode.con3('EXTERNAL_CONSTRUCTOR_WITH_BODY', 38, "External constructors cannot h ave a body"); 7430 static final ParserErrorCode EXTERNAL_CONSTRUCTOR_WITH_BODY = new ParserErrorC ode.con3('EXTERNAL_CONSTRUCTOR_WITH_BODY', 38, "External constructors cannot hav e a body");
7415 7431
7416 static const ParserErrorCode EXTERNAL_FIELD = const ParserErrorCode.con3('EXTE RNAL_FIELD', 39, "Fields cannot be declared to be 'external'"); 7432 static final ParserErrorCode EXTERNAL_FIELD = new ParserErrorCode.con3('EXTERN AL_FIELD', 39, "Fields cannot be declared to be 'external'");
7417 7433
7418 static const ParserErrorCode EXTERNAL_GETTER_WITH_BODY = const ParserErrorCode .con3('EXTERNAL_GETTER_WITH_BODY', 40, "External getters cannot have a body"); 7434 static final ParserErrorCode EXTERNAL_GETTER_WITH_BODY = new ParserErrorCode.c on3('EXTERNAL_GETTER_WITH_BODY', 40, "External getters cannot have a body");
7419 7435
7420 static const ParserErrorCode EXTERNAL_METHOD_WITH_BODY = const ParserErrorCode .con3('EXTERNAL_METHOD_WITH_BODY', 41, "External methods cannot have a body"); 7436 static final ParserErrorCode EXTERNAL_METHOD_WITH_BODY = new ParserErrorCode.c on3('EXTERNAL_METHOD_WITH_BODY', 41, "External methods cannot have a body");
7421 7437
7422 static const ParserErrorCode EXTERNAL_OPERATOR_WITH_BODY = const ParserErrorCo de.con3('EXTERNAL_OPERATOR_WITH_BODY', 42, "External operators cannot have a bod y"); 7438 static final ParserErrorCode EXTERNAL_OPERATOR_WITH_BODY = new ParserErrorCode .con3('EXTERNAL_OPERATOR_WITH_BODY', 42, "External operators cannot have a body" );
7423 7439
7424 static const ParserErrorCode EXTERNAL_SETTER_WITH_BODY = const ParserErrorCode .con3('EXTERNAL_SETTER_WITH_BODY', 43, "External setters cannot have a body"); 7440 static final ParserErrorCode EXTERNAL_SETTER_WITH_BODY = new ParserErrorCode.c on3('EXTERNAL_SETTER_WITH_BODY', 43, "External setters cannot have a body");
7425 7441
7426 static const ParserErrorCode EXTERNAL_TYPEDEF = const ParserErrorCode.con3('EX TERNAL_TYPEDEF', 44, "Type aliases cannot be declared to be 'external'"); 7442 static final ParserErrorCode EXTERNAL_TYPEDEF = new ParserErrorCode.con3('EXTE RNAL_TYPEDEF', 44, "Type aliases cannot be declared to be 'external'");
7427 7443
7428 static const ParserErrorCode FACTORY_TOP_LEVEL_DECLARATION = const ParserError Code.con3('FACTORY_TOP_LEVEL_DECLARATION', 45, "Top-level declarations cannot be declared to be 'factory'"); 7444 static final ParserErrorCode FACTORY_TOP_LEVEL_DECLARATION = new ParserErrorCo de.con3('FACTORY_TOP_LEVEL_DECLARATION', 45, "Top-level declarations cannot be d eclared to be 'factory'");
7429 7445
7430 static const ParserErrorCode FACTORY_WITHOUT_BODY = const ParserErrorCode.con3 ('FACTORY_WITHOUT_BODY', 46, "A non-redirecting 'factory' constructor must have a body"); 7446 static final ParserErrorCode FACTORY_WITHOUT_BODY = new ParserErrorCode.con3(' FACTORY_WITHOUT_BODY', 46, "A non-redirecting 'factory' constructor must have a body");
7431 7447
7432 static const ParserErrorCode FIELD_INITIALIZER_OUTSIDE_CONSTRUCTOR = const Par serErrorCode.con3('FIELD_INITIALIZER_OUTSIDE_CONSTRUCTOR', 47, "Field initialize rs can only be used in a constructor"); 7448 static final ParserErrorCode FIELD_INITIALIZER_OUTSIDE_CONSTRUCTOR = new Parse rErrorCode.con3('FIELD_INITIALIZER_OUTSIDE_CONSTRUCTOR', 47, "Field initializers can only be used in a constructor");
7433 7449
7434 static const ParserErrorCode FINAL_AND_VAR = const ParserErrorCode.con3('FINAL _AND_VAR', 48, "Members cannot be declared to be both 'final' and 'var'"); 7450 static final ParserErrorCode FINAL_AND_VAR = new ParserErrorCode.con3('FINAL_A ND_VAR', 48, "Members cannot be declared to be both 'final' and 'var'");
7435 7451
7436 static const ParserErrorCode FINAL_CLASS = const ParserErrorCode.con3('FINAL_C LASS', 49, "Classes cannot be declared to be 'final'"); 7452 static final ParserErrorCode FINAL_CLASS = new ParserErrorCode.con3('FINAL_CLA SS', 49, "Classes cannot be declared to be 'final'");
7437 7453
7438 static const ParserErrorCode FINAL_CONSTRUCTOR = const ParserErrorCode.con3('F INAL_CONSTRUCTOR', 50, "A constructor cannot be declared to be 'final'"); 7454 static final ParserErrorCode FINAL_CONSTRUCTOR = new ParserErrorCode.con3('FIN AL_CONSTRUCTOR', 50, "A constructor cannot be declared to be 'final'");
7439 7455
7440 static const ParserErrorCode FINAL_METHOD = const ParserErrorCode.con3('FINAL_ METHOD', 51, "Getters, setters and methods cannot be declared to be 'final'"); 7456 static final ParserErrorCode FINAL_METHOD = new ParserErrorCode.con3('FINAL_ME THOD', 51, "Getters, setters and methods cannot be declared to be 'final'");
7441 7457
7442 static const ParserErrorCode FINAL_TYPEDEF = const ParserErrorCode.con3('FINAL _TYPEDEF', 52, "Type aliases cannot be declared to be 'final'"); 7458 static final ParserErrorCode FINAL_TYPEDEF = new ParserErrorCode.con3('FINAL_T YPEDEF', 52, "Type aliases cannot be declared to be 'final'");
7443 7459
7444 static const ParserErrorCode FUNCTION_TYPED_PARAMETER_VAR = const ParserErrorC ode.con3('FUNCTION_TYPED_PARAMETER_VAR', 53, "Function typed parameters cannot s pecify 'const', 'final' or 'var' instead of return type"); 7460 static final ParserErrorCode FUNCTION_TYPED_PARAMETER_VAR = new ParserErrorCod e.con3('FUNCTION_TYPED_PARAMETER_VAR', 53, "Function typed parameters cannot spe cify 'const', 'final' or 'var' instead of return type");
7445 7461
7446 static const ParserErrorCode GETTER_IN_FUNCTION = const ParserErrorCode.con3(' GETTER_IN_FUNCTION', 54, "Getters cannot be defined within methods or functions" ); 7462 static final ParserErrorCode GETTER_IN_FUNCTION = new ParserErrorCode.con3('GE TTER_IN_FUNCTION', 54, "Getters cannot be defined within methods or functions");
7447 7463
7448 static const ParserErrorCode GETTER_WITH_PARAMETERS = const ParserErrorCode.co n3('GETTER_WITH_PARAMETERS', 55, "Getter should be declared without a parameter list"); 7464 static final ParserErrorCode GETTER_WITH_PARAMETERS = new ParserErrorCode.con3 ('GETTER_WITH_PARAMETERS', 55, "Getter should be declared without a parameter li st");
7449 7465
7450 static const ParserErrorCode ILLEGAL_ASSIGNMENT_TO_NON_ASSIGNABLE = const Pars erErrorCode.con3('ILLEGAL_ASSIGNMENT_TO_NON_ASSIGNABLE', 56, "Illegal assignment to non-assignable expression"); 7466 static final ParserErrorCode ILLEGAL_ASSIGNMENT_TO_NON_ASSIGNABLE = new Parser ErrorCode.con3('ILLEGAL_ASSIGNMENT_TO_NON_ASSIGNABLE', 56, "Illegal assignment t o non-assignable expression");
7451 7467
7452 static const ParserErrorCode IMPLEMENTS_BEFORE_EXTENDS = const ParserErrorCode .con3('IMPLEMENTS_BEFORE_EXTENDS', 57, "The extends clause must be before the im plements clause"); 7468 static final ParserErrorCode IMPLEMENTS_BEFORE_EXTENDS = new ParserErrorCode.c on3('IMPLEMENTS_BEFORE_EXTENDS', 57, "The extends clause must be before the impl ements clause");
7453 7469
7454 static const ParserErrorCode IMPLEMENTS_BEFORE_WITH = const ParserErrorCode.co n3('IMPLEMENTS_BEFORE_WITH', 58, "The with clause must be before the implements clause"); 7470 static final ParserErrorCode IMPLEMENTS_BEFORE_WITH = new ParserErrorCode.con3 ('IMPLEMENTS_BEFORE_WITH', 58, "The with clause must be before the implements cl ause");
7455 7471
7456 static const ParserErrorCode IMPORT_DIRECTIVE_AFTER_PART_DIRECTIVE = const Par serErrorCode.con3('IMPORT_DIRECTIVE_AFTER_PART_DIRECTIVE', 59, "Import directive s must preceed part directives"); 7472 static final ParserErrorCode IMPORT_DIRECTIVE_AFTER_PART_DIRECTIVE = new Parse rErrorCode.con3('IMPORT_DIRECTIVE_AFTER_PART_DIRECTIVE', 59, "Import directives must preceed part directives");
7457 7473
7458 static const ParserErrorCode INITIALIZED_VARIABLE_IN_FOR_EACH = const ParserEr rorCode.con3('INITIALIZED_VARIABLE_IN_FOR_EACH', 60, "The loop variable in a for -each loop cannot be initialized"); 7474 static final ParserErrorCode INITIALIZED_VARIABLE_IN_FOR_EACH = new ParserErro rCode.con3('INITIALIZED_VARIABLE_IN_FOR_EACH', 60, "The loop variable in a for-e ach loop cannot be initialized");
7459 7475
7460 static const ParserErrorCode INVALID_CODE_POINT = const ParserErrorCode.con3(' INVALID_CODE_POINT', 61, "The escape sequence '%s' is not a valid code point"); 7476 static final ParserErrorCode INVALID_CODE_POINT = new ParserErrorCode.con3('IN VALID_CODE_POINT', 61, "The escape sequence '%s' is not a valid code point");
7461 7477
7462 static const ParserErrorCode INVALID_COMMENT_REFERENCE = const ParserErrorCode .con3('INVALID_COMMENT_REFERENCE', 62, "Comment references should contain a poss ibly prefixed identifier and can start with 'new', but should not contain anythi ng else"); 7478 static final ParserErrorCode INVALID_COMMENT_REFERENCE = new ParserErrorCode.c on3('INVALID_COMMENT_REFERENCE', 62, "Comment references should contain a possib ly prefixed identifier and can start with 'new', but should not contain anything else");
7463 7479
7464 static const ParserErrorCode INVALID_HEX_ESCAPE = const ParserErrorCode.con3(' INVALID_HEX_ESCAPE', 63, "An escape sequence starting with '\\x' must be followe d by 2 hexidecimal digits"); 7480 static final ParserErrorCode INVALID_HEX_ESCAPE = new ParserErrorCode.con3('IN VALID_HEX_ESCAPE', 63, "An escape sequence starting with '\\x' must be followed by 2 hexidecimal digits");
7465 7481
7466 static const ParserErrorCode INVALID_OPERATOR = const ParserErrorCode.con3('IN VALID_OPERATOR', 64, "The string '%s' is not a valid operator"); 7482 static final ParserErrorCode INVALID_OPERATOR = new ParserErrorCode.con3('INVA LID_OPERATOR', 64, "The string '%s' is not a valid operator");
7467 7483
7468 static const ParserErrorCode INVALID_OPERATOR_FOR_SUPER = const ParserErrorCod e.con3('INVALID_OPERATOR_FOR_SUPER', 65, "The operator '%s' cannot be used with 'super'"); 7484 static final ParserErrorCode INVALID_OPERATOR_FOR_SUPER = new ParserErrorCode. con3('INVALID_OPERATOR_FOR_SUPER', 65, "The operator '%s' cannot be used with 's uper'");
7469 7485
7470 static const ParserErrorCode INVALID_UNICODE_ESCAPE = const ParserErrorCode.co n3('INVALID_UNICODE_ESCAPE', 66, "An escape sequence starting with '\\u' must be followed by 4 hexidecimal digits or from 1 to 6 digits between '{' and '}'"); 7486 static final ParserErrorCode INVALID_UNICODE_ESCAPE = new ParserErrorCode.con3 ('INVALID_UNICODE_ESCAPE', 66, "An escape sequence starting with '\\u' must be f ollowed by 4 hexidecimal digits or from 1 to 6 digits between '{' and '}'");
7471 7487
7472 static const ParserErrorCode LIBRARY_DIRECTIVE_NOT_FIRST = const ParserErrorCo de.con3('LIBRARY_DIRECTIVE_NOT_FIRST', 67, "The library directive must appear be fore all other directives"); 7488 static final ParserErrorCode LIBRARY_DIRECTIVE_NOT_FIRST = new ParserErrorCode .con3('LIBRARY_DIRECTIVE_NOT_FIRST', 67, "The library directive must appear befo re all other directives");
7473 7489
7474 static const ParserErrorCode LOCAL_FUNCTION_DECLARATION_MODIFIER = const Parse rErrorCode.con3('LOCAL_FUNCTION_DECLARATION_MODIFIER', 68, "Local function decla rations cannot specify any modifier"); 7490 static final ParserErrorCode LOCAL_FUNCTION_DECLARATION_MODIFIER = new ParserE rrorCode.con3('LOCAL_FUNCTION_DECLARATION_MODIFIER', 68, "Local function declara tions cannot specify any modifier");
7475 7491
7476 static const ParserErrorCode MISSING_ASSIGNABLE_SELECTOR = const ParserErrorCo de.con3('MISSING_ASSIGNABLE_SELECTOR', 69, "Missing selector such as \".<identif ier>\" or \"[0]\""); 7492 static final ParserErrorCode MISSING_ASSIGNABLE_SELECTOR = new ParserErrorCode .con3('MISSING_ASSIGNABLE_SELECTOR', 69, "Missing selector such as \".<identifie r>\" or \"[0]\"");
7477 7493
7478 static const ParserErrorCode MISSING_CATCH_OR_FINALLY = const ParserErrorCode. con3('MISSING_CATCH_OR_FINALLY', 70, "A try statement must have either a catch o r finally clause"); 7494 static final ParserErrorCode MISSING_CATCH_OR_FINALLY = new ParserErrorCode.co n3('MISSING_CATCH_OR_FINALLY', 70, "A try statement must have either a catch or finally clause");
7479 7495
7480 static const ParserErrorCode MISSING_CLASS_BODY = const ParserErrorCode.con3(' MISSING_CLASS_BODY', 71, "A class definition must have a body, even if it is emp ty"); 7496 static final ParserErrorCode MISSING_CLASS_BODY = new ParserErrorCode.con3('MI SSING_CLASS_BODY', 71, "A class definition must have a body, even if it is empty ");
7481 7497
7482 static const ParserErrorCode MISSING_CLOSING_PARENTHESIS = const ParserErrorCo de.con3('MISSING_CLOSING_PARENTHESIS', 72, "The closing parenthesis is missing") ; 7498 static final ParserErrorCode MISSING_CLOSING_PARENTHESIS = new ParserErrorCode .con3('MISSING_CLOSING_PARENTHESIS', 72, "The closing parenthesis is missing");
7483 7499
7484 static const ParserErrorCode MISSING_CONST_FINAL_VAR_OR_TYPE = const ParserErr orCode.con3('MISSING_CONST_FINAL_VAR_OR_TYPE', 73, "Variables must be declared u sing the keywords 'const', 'final', 'var' or a type name"); 7500 static final ParserErrorCode MISSING_CONST_FINAL_VAR_OR_TYPE = new ParserError Code.con3('MISSING_CONST_FINAL_VAR_OR_TYPE', 73, "Variables must be declared usi ng the keywords 'const', 'final', 'var' or a type name");
7485 7501
7486 static const ParserErrorCode MISSING_EXPRESSION_IN_THROW = const ParserErrorCo de.con3('MISSING_EXPRESSION_IN_THROW', 74, "Throw expressions must compute the o bject to be thrown"); 7502 static final ParserErrorCode MISSING_EXPRESSION_IN_THROW = new ParserErrorCode .con3('MISSING_EXPRESSION_IN_THROW', 74, "Throw expressions must compute the obj ect to be thrown");
7487 7503
7488 static const ParserErrorCode MISSING_FUNCTION_BODY = const ParserErrorCode.con 3('MISSING_FUNCTION_BODY', 75, "A function body must be provided"); 7504 static final ParserErrorCode MISSING_FUNCTION_BODY = new ParserErrorCode.con3( 'MISSING_FUNCTION_BODY', 75, "A function body must be provided");
7489 7505
7490 static const ParserErrorCode MISSING_FUNCTION_PARAMETERS = const ParserErrorCo de.con3('MISSING_FUNCTION_PARAMETERS', 76, "Functions must have an explicit list of parameters"); 7506 static final ParserErrorCode MISSING_FUNCTION_PARAMETERS = new ParserErrorCode .con3('MISSING_FUNCTION_PARAMETERS', 76, "Functions must have an explicit list o f parameters");
7491 7507
7492 static const ParserErrorCode MISSING_IDENTIFIER = const ParserErrorCode.con3(' MISSING_IDENTIFIER', 77, "Expected an identifier"); 7508 static final ParserErrorCode MISSING_IDENTIFIER = new ParserErrorCode.con3('MI SSING_IDENTIFIER', 77, "Expected an identifier");
7493 7509
7494 static const ParserErrorCode MISSING_KEYWORD_OPERATOR = const ParserErrorCode. con3('MISSING_KEYWORD_OPERATOR', 78, "Operator declarations must be preceeded by the keyword 'operator'"); 7510 static final ParserErrorCode MISSING_KEYWORD_OPERATOR = new ParserErrorCode.co n3('MISSING_KEYWORD_OPERATOR', 78, "Operator declarations must be preceeded by t he keyword 'operator'");
7495 7511
7496 static const ParserErrorCode MISSING_NAME_IN_LIBRARY_DIRECTIVE = const ParserE rrorCode.con3('MISSING_NAME_IN_LIBRARY_DIRECTIVE', 79, "Library directives must include a library name"); 7512 static final ParserErrorCode MISSING_NAME_IN_LIBRARY_DIRECTIVE = new ParserErr orCode.con3('MISSING_NAME_IN_LIBRARY_DIRECTIVE', 79, "Library directives must in clude a library name");
7497 7513
7498 static const ParserErrorCode MISSING_NAME_IN_PART_OF_DIRECTIVE = const ParserE rrorCode.con3('MISSING_NAME_IN_PART_OF_DIRECTIVE', 80, "Library directives must include a library name"); 7514 static final ParserErrorCode MISSING_NAME_IN_PART_OF_DIRECTIVE = new ParserErr orCode.con3('MISSING_NAME_IN_PART_OF_DIRECTIVE', 80, "Library directives must in clude a library name");
7499 7515
7500 static const ParserErrorCode MISSING_STATEMENT = const ParserErrorCode.con3('M ISSING_STATEMENT', 81, "Expected a statement"); 7516 static final ParserErrorCode MISSING_STATEMENT = new ParserErrorCode.con3('MIS SING_STATEMENT', 81, "Expected a statement");
7501 7517
7502 static const ParserErrorCode MISSING_TERMINATOR_FOR_PARAMETER_GROUP = const Pa rserErrorCode.con3('MISSING_TERMINATOR_FOR_PARAMETER_GROUP', 82, "There is no '% s' to close the parameter group"); 7518 static final ParserErrorCode MISSING_TERMINATOR_FOR_PARAMETER_GROUP = new Pars erErrorCode.con3('MISSING_TERMINATOR_FOR_PARAMETER_GROUP', 82, "There is no '%s' to close the parameter group");
7503 7519
7504 static const ParserErrorCode MISSING_TYPEDEF_PARAMETERS = const ParserErrorCod e.con3('MISSING_TYPEDEF_PARAMETERS', 83, "Type aliases for functions must have a n explicit list of parameters"); 7520 static final ParserErrorCode MISSING_TYPEDEF_PARAMETERS = new ParserErrorCode. con3('MISSING_TYPEDEF_PARAMETERS', 83, "Type aliases for functions must have an explicit list of parameters");
7505 7521
7506 static const ParserErrorCode MISSING_VARIABLE_IN_FOR_EACH = const ParserErrorC ode.con3('MISSING_VARIABLE_IN_FOR_EACH', 84, "A loop variable must be declared i n a for-each loop before the 'in', but none were found"); 7522 static final ParserErrorCode MISSING_VARIABLE_IN_FOR_EACH = new ParserErrorCod e.con3('MISSING_VARIABLE_IN_FOR_EACH', 84, "A loop variable must be declared in a for-each loop before the 'in', but none were found");
7507 7523
7508 static const ParserErrorCode MIXED_PARAMETER_GROUPS = const ParserErrorCode.co n3('MIXED_PARAMETER_GROUPS', 85, "Cannot have both positional and named paramete rs in a single parameter list"); 7524 static final ParserErrorCode MIXED_PARAMETER_GROUPS = new ParserErrorCode.con3 ('MIXED_PARAMETER_GROUPS', 85, "Cannot have both positional and named parameters in a single parameter list");
7509 7525
7510 static const ParserErrorCode MULTIPLE_EXTENDS_CLAUSES = const ParserErrorCode. con3('MULTIPLE_EXTENDS_CLAUSES', 86, "Each class definition can have at most one extends clause"); 7526 static final ParserErrorCode MULTIPLE_EXTENDS_CLAUSES = new ParserErrorCode.co n3('MULTIPLE_EXTENDS_CLAUSES', 86, "Each class definition can have at most one e xtends clause");
7511 7527
7512 static const ParserErrorCode MULTIPLE_IMPLEMENTS_CLAUSES = const ParserErrorCo de.con3('MULTIPLE_IMPLEMENTS_CLAUSES', 87, "Each class definition can have at mo st one implements clause"); 7528 static final ParserErrorCode MULTIPLE_IMPLEMENTS_CLAUSES = new ParserErrorCode .con3('MULTIPLE_IMPLEMENTS_CLAUSES', 87, "Each class definition can have at most one implements clause");
7513 7529
7514 static const ParserErrorCode MULTIPLE_LIBRARY_DIRECTIVES = const ParserErrorCo de.con3('MULTIPLE_LIBRARY_DIRECTIVES', 88, "Only one library directive may be de clared in a file"); 7530 static final ParserErrorCode MULTIPLE_LIBRARY_DIRECTIVES = new ParserErrorCode .con3('MULTIPLE_LIBRARY_DIRECTIVES', 88, "Only one library directive may be decl ared in a file");
7515 7531
7516 static const ParserErrorCode MULTIPLE_NAMED_PARAMETER_GROUPS = const ParserErr orCode.con3('MULTIPLE_NAMED_PARAMETER_GROUPS', 89, "Cannot have multiple groups of named parameters in a single parameter list"); 7532 static final ParserErrorCode MULTIPLE_NAMED_PARAMETER_GROUPS = new ParserError Code.con3('MULTIPLE_NAMED_PARAMETER_GROUPS', 89, "Cannot have multiple groups of named parameters in a single parameter list");
7517 7533
7518 static const ParserErrorCode MULTIPLE_PART_OF_DIRECTIVES = const ParserErrorCo de.con3('MULTIPLE_PART_OF_DIRECTIVES', 90, "Only one part-of directive may be de clared in a file"); 7534 static final ParserErrorCode MULTIPLE_PART_OF_DIRECTIVES = new ParserErrorCode .con3('MULTIPLE_PART_OF_DIRECTIVES', 90, "Only one part-of directive may be decl ared in a file");
7519 7535
7520 static const ParserErrorCode MULTIPLE_POSITIONAL_PARAMETER_GROUPS = const Pars erErrorCode.con3('MULTIPLE_POSITIONAL_PARAMETER_GROUPS', 91, "Cannot have multip le groups of positional parameters in a single parameter list"); 7536 static final ParserErrorCode MULTIPLE_POSITIONAL_PARAMETER_GROUPS = new Parser ErrorCode.con3('MULTIPLE_POSITIONAL_PARAMETER_GROUPS', 91, "Cannot have multiple groups of positional parameters in a single parameter list");
7521 7537
7522 static const ParserErrorCode MULTIPLE_VARIABLES_IN_FOR_EACH = const ParserErro rCode.con3('MULTIPLE_VARIABLES_IN_FOR_EACH', 92, "A single loop variable must be declared in a for-each loop before the 'in', but %s were found"); 7538 static final ParserErrorCode MULTIPLE_VARIABLES_IN_FOR_EACH = new ParserErrorC ode.con3('MULTIPLE_VARIABLES_IN_FOR_EACH', 92, "A single loop variable must be d eclared in a for-each loop before the 'in', but %s were found");
7523 7539
7524 static const ParserErrorCode MULTIPLE_WITH_CLAUSES = const ParserErrorCode.con 3('MULTIPLE_WITH_CLAUSES', 93, "Each class definition can have at most one with clause"); 7540 static final ParserErrorCode MULTIPLE_WITH_CLAUSES = new ParserErrorCode.con3( 'MULTIPLE_WITH_CLAUSES', 93, "Each class definition can have at most one with cl ause");
7525 7541
7526 static const ParserErrorCode NAMED_FUNCTION_EXPRESSION = const ParserErrorCode .con3('NAMED_FUNCTION_EXPRESSION', 94, "Function expressions cannot be named"); 7542 static final ParserErrorCode NAMED_FUNCTION_EXPRESSION = new ParserErrorCode.c on3('NAMED_FUNCTION_EXPRESSION', 94, "Function expressions cannot be named");
7527 7543
7528 static const ParserErrorCode NAMED_PARAMETER_OUTSIDE_GROUP = const ParserError Code.con3('NAMED_PARAMETER_OUTSIDE_GROUP', 95, "Named parameters must be enclose d in curly braces ('{' and '}')"); 7544 static final ParserErrorCode NAMED_PARAMETER_OUTSIDE_GROUP = new ParserErrorCo de.con3('NAMED_PARAMETER_OUTSIDE_GROUP', 95, "Named parameters must be enclosed in curly braces ('{' and '}')");
7529 7545
7530 static const ParserErrorCode NATIVE_CLAUSE_IN_NON_SDK_CODE = const ParserError Code.con3('NATIVE_CLAUSE_IN_NON_SDK_CODE', 96, "Native clause can only be used i n the SDK and code that is loaded through native extensions"); 7546 static final ParserErrorCode NATIVE_CLAUSE_IN_NON_SDK_CODE = new ParserErrorCo de.con3('NATIVE_CLAUSE_IN_NON_SDK_CODE', 96, "Native clause can only be used in the SDK and code that is loaded through native extensions");
7531 7547
7532 static const ParserErrorCode NATIVE_FUNCTION_BODY_IN_NON_SDK_CODE = const Pars erErrorCode.con3('NATIVE_FUNCTION_BODY_IN_NON_SDK_CODE', 97, "Native functions c an only be declared in the SDK and code that is loaded through native extensions "); 7548 static final ParserErrorCode NATIVE_FUNCTION_BODY_IN_NON_SDK_CODE = new Parser ErrorCode.con3('NATIVE_FUNCTION_BODY_IN_NON_SDK_CODE', 97, "Native functions can only be declared in the SDK and code that is loaded through native extensions") ;
7533 7549
7534 static const ParserErrorCode NON_CONSTRUCTOR_FACTORY = const ParserErrorCode.c on3('NON_CONSTRUCTOR_FACTORY', 98, "Only constructors can be declared to be a 'f actory'"); 7550 static final ParserErrorCode NON_CONSTRUCTOR_FACTORY = new ParserErrorCode.con 3('NON_CONSTRUCTOR_FACTORY', 98, "Only constructors can be declared to be a 'fac tory'");
7535 7551
7536 static const ParserErrorCode NON_IDENTIFIER_LIBRARY_NAME = const ParserErrorCo de.con3('NON_IDENTIFIER_LIBRARY_NAME', 99, "The name of a library must be an ide ntifier"); 7552 static final ParserErrorCode NON_IDENTIFIER_LIBRARY_NAME = new ParserErrorCode .con3('NON_IDENTIFIER_LIBRARY_NAME', 99, "The name of a library must be an ident ifier");
7537 7553
7538 static const ParserErrorCode NON_PART_OF_DIRECTIVE_IN_PART = const ParserError Code.con3('NON_PART_OF_DIRECTIVE_IN_PART', 100, "The part-of directive must be t he only directive in a part"); 7554 static final ParserErrorCode NON_PART_OF_DIRECTIVE_IN_PART = new ParserErrorCo de.con3('NON_PART_OF_DIRECTIVE_IN_PART', 100, "The part-of directive must be the only directive in a part");
7539 7555
7540 static const ParserErrorCode NON_USER_DEFINABLE_OPERATOR = const ParserErrorCo de.con3('NON_USER_DEFINABLE_OPERATOR', 101, "The operator '%s' is not user defin able"); 7556 static final ParserErrorCode NON_USER_DEFINABLE_OPERATOR = new ParserErrorCode .con3('NON_USER_DEFINABLE_OPERATOR', 101, "The operator '%s' is not user definab le");
7541 7557
7542 static const ParserErrorCode NORMAL_BEFORE_OPTIONAL_PARAMETERS = const ParserE rrorCode.con3('NORMAL_BEFORE_OPTIONAL_PARAMETERS', 102, "Normal parameters must occur before optional parameters"); 7558 static final ParserErrorCode NORMAL_BEFORE_OPTIONAL_PARAMETERS = new ParserErr orCode.con3('NORMAL_BEFORE_OPTIONAL_PARAMETERS', 102, "Normal parameters must oc cur before optional parameters");
7543 7559
7544 static const ParserErrorCode POSITIONAL_AFTER_NAMED_ARGUMENT = const ParserErr orCode.con3('POSITIONAL_AFTER_NAMED_ARGUMENT', 103, "Positional arguments must o ccur before named arguments"); 7560 static final ParserErrorCode POSITIONAL_AFTER_NAMED_ARGUMENT = new ParserError Code.con3('POSITIONAL_AFTER_NAMED_ARGUMENT', 103, "Positional arguments must occ ur before named arguments");
7545 7561
7546 static const ParserErrorCode POSITIONAL_PARAMETER_OUTSIDE_GROUP = const Parser ErrorCode.con3('POSITIONAL_PARAMETER_OUTSIDE_GROUP', 104, "Positional parameters must be enclosed in square brackets ('[' and ']')"); 7562 static final ParserErrorCode POSITIONAL_PARAMETER_OUTSIDE_GROUP = new ParserEr rorCode.con3('POSITIONAL_PARAMETER_OUTSIDE_GROUP', 104, "Positional parameters m ust be enclosed in square brackets ('[' and ']')");
7547 7563
7548 static const ParserErrorCode REDIRECTION_IN_NON_FACTORY_CONSTRUCTOR = const Pa rserErrorCode.con3('REDIRECTION_IN_NON_FACTORY_CONSTRUCTOR', 105, "Only factory constructor can specify '=' redirection."); 7564 static final ParserErrorCode REDIRECTION_IN_NON_FACTORY_CONSTRUCTOR = new Pars erErrorCode.con3('REDIRECTION_IN_NON_FACTORY_CONSTRUCTOR', 105, "Only factory co nstructor can specify '=' redirection.");
7549 7565
7550 static const ParserErrorCode SETTER_IN_FUNCTION = const ParserErrorCode.con3(' SETTER_IN_FUNCTION', 106, "Setters cannot be defined within methods or functions "); 7566 static final ParserErrorCode SETTER_IN_FUNCTION = new ParserErrorCode.con3('SE TTER_IN_FUNCTION', 106, "Setters cannot be defined within methods or functions") ;
7551 7567
7552 static const ParserErrorCode STATIC_AFTER_CONST = const ParserErrorCode.con3(' STATIC_AFTER_CONST', 107, "The modifier 'static' should be before the modifier ' const'"); 7568 static final ParserErrorCode STATIC_AFTER_CONST = new ParserErrorCode.con3('ST ATIC_AFTER_CONST', 107, "The modifier 'static' should be before the modifier 'co nst'");
7553 7569
7554 static const ParserErrorCode STATIC_AFTER_FINAL = const ParserErrorCode.con3(' STATIC_AFTER_FINAL', 108, "The modifier 'static' should be before the modifier ' final'"); 7570 static final ParserErrorCode STATIC_AFTER_FINAL = new ParserErrorCode.con3('ST ATIC_AFTER_FINAL', 108, "The modifier 'static' should be before the modifier 'fi nal'");
7555 7571
7556 static const ParserErrorCode STATIC_AFTER_VAR = const ParserErrorCode.con3('ST ATIC_AFTER_VAR', 109, "The modifier 'static' should be before the modifier 'var' "); 7572 static final ParserErrorCode STATIC_AFTER_VAR = new ParserErrorCode.con3('STAT IC_AFTER_VAR', 109, "The modifier 'static' should be before the modifier 'var'") ;
7557 7573
7558 static const ParserErrorCode STATIC_CONSTRUCTOR = const ParserErrorCode.con3(' STATIC_CONSTRUCTOR', 110, "Constructors cannot be static"); 7574 static final ParserErrorCode STATIC_CONSTRUCTOR = new ParserErrorCode.con3('ST ATIC_CONSTRUCTOR', 110, "Constructors cannot be static");
7559 7575
7560 static const ParserErrorCode STATIC_GETTER_WITHOUT_BODY = const ParserErrorCod e.con3('STATIC_GETTER_WITHOUT_BODY', 111, "A 'static' getter must have a body"); 7576 static final ParserErrorCode STATIC_GETTER_WITHOUT_BODY = new ParserErrorCode. con3('STATIC_GETTER_WITHOUT_BODY', 111, "A 'static' getter must have a body");
7561 7577
7562 static const ParserErrorCode STATIC_OPERATOR = const ParserErrorCode.con3('STA TIC_OPERATOR', 112, "Operators cannot be static"); 7578 static final ParserErrorCode STATIC_OPERATOR = new ParserErrorCode.con3('STATI C_OPERATOR', 112, "Operators cannot be static");
7563 7579
7564 static const ParserErrorCode STATIC_SETTER_WITHOUT_BODY = const ParserErrorCod e.con3('STATIC_SETTER_WITHOUT_BODY', 113, "A 'static' setter must have a body"); 7580 static final ParserErrorCode STATIC_SETTER_WITHOUT_BODY = new ParserErrorCode. con3('STATIC_SETTER_WITHOUT_BODY', 113, "A 'static' setter must have a body");
7565 7581
7566 static const ParserErrorCode STATIC_TOP_LEVEL_DECLARATION = const ParserErrorC ode.con3('STATIC_TOP_LEVEL_DECLARATION', 114, "Top-level declarations cannot be declared to be 'static'"); 7582 static final ParserErrorCode STATIC_TOP_LEVEL_DECLARATION = new ParserErrorCod e.con3('STATIC_TOP_LEVEL_DECLARATION', 114, "Top-level declarations cannot be de clared to be 'static'");
7567 7583
7568 static const ParserErrorCode SWITCH_HAS_CASE_AFTER_DEFAULT_CASE = const Parser ErrorCode.con3('SWITCH_HAS_CASE_AFTER_DEFAULT_CASE', 115, "The 'default' case sh ould be the last case in a switch statement"); 7584 static final ParserErrorCode SWITCH_HAS_CASE_AFTER_DEFAULT_CASE = new ParserEr rorCode.con3('SWITCH_HAS_CASE_AFTER_DEFAULT_CASE', 115, "The 'default' case shou ld be the last case in a switch statement");
7569 7585
7570 static const ParserErrorCode SWITCH_HAS_MULTIPLE_DEFAULT_CASES = const ParserE rrorCode.con3('SWITCH_HAS_MULTIPLE_DEFAULT_CASES', 116, "The 'default' case can only be declared once"); 7586 static final ParserErrorCode SWITCH_HAS_MULTIPLE_DEFAULT_CASES = new ParserErr orCode.con3('SWITCH_HAS_MULTIPLE_DEFAULT_CASES', 116, "The 'default' case can on ly be declared once");
7571 7587
7572 static const ParserErrorCode TOP_LEVEL_OPERATOR = const ParserErrorCode.con3(' TOP_LEVEL_OPERATOR', 117, "Operators must be declared within a class"); 7588 static final ParserErrorCode TOP_LEVEL_OPERATOR = new ParserErrorCode.con3('TO P_LEVEL_OPERATOR', 117, "Operators must be declared within a class");
7573 7589
7574 static const ParserErrorCode UNEXPECTED_TERMINATOR_FOR_PARAMETER_GROUP = const ParserErrorCode.con3('UNEXPECTED_TERMINATOR_FOR_PARAMETER_GROUP', 118, "There i s no '%s' to open a parameter group"); 7590 static final ParserErrorCode UNEXPECTED_TERMINATOR_FOR_PARAMETER_GROUP = new P arserErrorCode.con3('UNEXPECTED_TERMINATOR_FOR_PARAMETER_GROUP', 118, "There is no '%s' to open a parameter group");
7575 7591
7576 static const ParserErrorCode UNEXPECTED_TOKEN = const ParserErrorCode.con3('UN EXPECTED_TOKEN', 119, "Unexpected token '%s'"); 7592 static final ParserErrorCode UNEXPECTED_TOKEN = new ParserErrorCode.con3('UNEX PECTED_TOKEN', 119, "Unexpected token '%s'");
7577 7593
7578 static const ParserErrorCode WITH_BEFORE_EXTENDS = const ParserErrorCode.con3( 'WITH_BEFORE_EXTENDS', 120, "The extends clause must be before the with clause") ; 7594 static final ParserErrorCode WITH_BEFORE_EXTENDS = new ParserErrorCode.con3('W ITH_BEFORE_EXTENDS', 120, "The extends clause must be before the with clause");
7579 7595
7580 static const ParserErrorCode WITH_WITHOUT_EXTENDS = const ParserErrorCode.con3 ('WITH_WITHOUT_EXTENDS', 121, "The with clause cannot be used without an extends clause"); 7596 static final ParserErrorCode WITH_WITHOUT_EXTENDS = new ParserErrorCode.con3(' WITH_WITHOUT_EXTENDS', 121, "The with clause cannot be used without an extends c lause");
7581 7597
7582 static const ParserErrorCode WRONG_SEPARATOR_FOR_NAMED_PARAMETER = const Parse rErrorCode.con3('WRONG_SEPARATOR_FOR_NAMED_PARAMETER', 122, "The default value o f a named parameter should be preceeded by ':'"); 7598 static final ParserErrorCode WRONG_SEPARATOR_FOR_NAMED_PARAMETER = new ParserE rrorCode.con3('WRONG_SEPARATOR_FOR_NAMED_PARAMETER', 122, "The default value of a named parameter should be preceeded by ':'");
7583 7599
7584 static const ParserErrorCode WRONG_SEPARATOR_FOR_POSITIONAL_PARAMETER = const ParserErrorCode.con3('WRONG_SEPARATOR_FOR_POSITIONAL_PARAMETER', 123, "The defau lt value of a positional parameter should be preceeded by '='"); 7600 static final ParserErrorCode WRONG_SEPARATOR_FOR_POSITIONAL_PARAMETER = new Pa rserErrorCode.con3('WRONG_SEPARATOR_FOR_POSITIONAL_PARAMETER', 123, "The default value of a positional parameter should be preceeded by '='");
7585 7601
7586 static const ParserErrorCode WRONG_TERMINATOR_FOR_PARAMETER_GROUP = const Pars erErrorCode.con3('WRONG_TERMINATOR_FOR_PARAMETER_GROUP', 124, "Expected '%s' to close parameter group"); 7602 static final ParserErrorCode WRONG_TERMINATOR_FOR_PARAMETER_GROUP = new Parser ErrorCode.con3('WRONG_TERMINATOR_FOR_PARAMETER_GROUP', 124, "Expected '%s' to cl ose parameter group");
7587 7603
7588 static const ParserErrorCode VAR_AND_TYPE = const ParserErrorCode.con3('VAR_AN D_TYPE', 125, "Variables cannot be declared using both 'var' and a type name; re move the 'var'"); 7604 static final ParserErrorCode VAR_AND_TYPE = new ParserErrorCode.con3('VAR_AND_ TYPE', 125, "Variables cannot be declared using both 'var' and a type name; remo ve the 'var'");
7589 7605
7590 static const ParserErrorCode VAR_AS_TYPE_NAME = const ParserErrorCode.con3('VA R_AS_TYPE_NAME', 126, "The keyword 'var' cannot be used as a type name"); 7606 static final ParserErrorCode VAR_AS_TYPE_NAME = new ParserErrorCode.con3('VAR_ AS_TYPE_NAME', 126, "The keyword 'var' cannot be used as a type name");
7591 7607
7592 static const ParserErrorCode VAR_CLASS = const ParserErrorCode.con3('VAR_CLASS ', 127, "Classes cannot be declared to be 'var'"); 7608 static final ParserErrorCode VAR_CLASS = new ParserErrorCode.con3('VAR_CLASS', 127, "Classes cannot be declared to be 'var'");
7593 7609
7594 static const ParserErrorCode VAR_RETURN_TYPE = const ParserErrorCode.con3('VAR _RETURN_TYPE', 128, "The return type cannot be 'var'"); 7610 static final ParserErrorCode VAR_RETURN_TYPE = new ParserErrorCode.con3('VAR_R ETURN_TYPE', 128, "The return type cannot be 'var'");
7595 7611
7596 static const ParserErrorCode VAR_TYPEDEF = const ParserErrorCode.con3('VAR_TYP EDEF', 129, "Type aliases cannot be declared to be 'var'"); 7612 static final ParserErrorCode VAR_TYPEDEF = new ParserErrorCode.con3('VAR_TYPED EF', 129, "Type aliases cannot be declared to be 'var'");
7597 7613
7598 static const ParserErrorCode VOID_PARAMETER = const ParserErrorCode.con3('VOID _PARAMETER', 130, "Parameters cannot have a type of 'void'"); 7614 static final ParserErrorCode VOID_PARAMETER = new ParserErrorCode.con3('VOID_P ARAMETER', 130, "Parameters cannot have a type of 'void'");
7599 7615
7600 static const ParserErrorCode VOID_VARIABLE = const ParserErrorCode.con3('VOID_ VARIABLE', 131, "Variables cannot have a type of 'void'"); 7616 static final ParserErrorCode VOID_VARIABLE = new ParserErrorCode.con3('VOID_VA RIABLE', 131, "Variables cannot have a type of 'void'");
7601 7617
7602 static const List<ParserErrorCode> values = const [ 7618 static final List<ParserErrorCode> values = [
7603 ABSTRACT_CLASS_MEMBER, 7619 ABSTRACT_CLASS_MEMBER,
7604 ABSTRACT_STATIC_METHOD, 7620 ABSTRACT_STATIC_METHOD,
7605 ABSTRACT_TOP_LEVEL_FUNCTION, 7621 ABSTRACT_TOP_LEVEL_FUNCTION,
7606 ABSTRACT_TOP_LEVEL_VARIABLE, 7622 ABSTRACT_TOP_LEVEL_VARIABLE,
7607 ABSTRACT_TYPEDEF, 7623 ABSTRACT_TYPEDEF,
7608 ASSERT_DOES_NOT_TAKE_ASSIGNMENT, 7624 ASSERT_DOES_NOT_TAKE_ASSIGNMENT,
7609 ASSERT_DOES_NOT_TAKE_CASCADE, 7625 ASSERT_DOES_NOT_TAKE_CASCADE,
7610 ASSERT_DOES_NOT_TAKE_THROW, 7626 ASSERT_DOES_NOT_TAKE_THROW,
7611 ASSERT_DOES_NOT_TAKE_RETHROW, 7627 ASSERT_DOES_NOT_TAKE_RETHROW,
7612 BREAK_OUTSIDE_OF_LOOP, 7628 BREAK_OUTSIDE_OF_LOOP,
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
7729 VAR_AS_TYPE_NAME, 7745 VAR_AS_TYPE_NAME,
7730 VAR_CLASS, 7746 VAR_CLASS,
7731 VAR_RETURN_TYPE, 7747 VAR_RETURN_TYPE,
7732 VAR_TYPEDEF, 7748 VAR_TYPEDEF,
7733 VOID_PARAMETER, 7749 VOID_PARAMETER,
7734 VOID_VARIABLE]; 7750 VOID_VARIABLE];
7735 7751
7736 /** 7752 /**
7737 * The severity of this error. 7753 * The severity of this error.
7738 */ 7754 */
7739 final ErrorSeverity errorSeverity; 7755 ErrorSeverity _severity;
7740 7756
7741 /** 7757 /**
7742 * The template used to create the message to be displayed for this error. 7758 * The template used to create the message to be displayed for this error.
7743 */ 7759 */
7744 final String message; 7760 String _message;
7745 7761
7746 /** 7762 /**
7747 * The template used to create the correction to be displayed for this error, or `null` if 7763 * The template used to create the correction to be displayed for this error, or `null` if
7748 * there is no correction information for this error. 7764 * there is no correction information for this error.
7749 */ 7765 */
7750 final String correction; 7766 String correction8;
7751 7767
7752 /** 7768 /**
7753 * Initialize a newly created error code to have the given severity and messag e. 7769 * Initialize a newly created error code to have the given severity and messag e.
7754 * 7770 *
7755 * @param errorSeverity the severity of the error 7771 * @param severity the severity of the error
7756 * @param message the message template used to create the message to be displa yed for the error 7772 * @param message the message template used to create the message to be displa yed for the error
7757 */ 7773 */
7758 const ParserErrorCode.con1(String name, int ordinal, ErrorSeverity errorSeveri ty, String message) : this.con2(name, ordinal, errorSeverity, message, null); 7774 ParserErrorCode.con1(String name, int ordinal, ErrorSeverity severity, String message) : super(name, ordinal) {
7775 this._severity = severity;
7776 this._message = message;
7777 }
7759 7778
7760 /** 7779 /**
7761 * Initialize a newly created error code to have the given severity, message a nd correction. 7780 * Initialize a newly created error code to have the given severity, message a nd correction.
7762 * 7781 *
7763 * @param errorSeverity the severity of the error 7782 * @param severity the severity of the error
7764 * @param message the template used to create the message to be displayed for the error 7783 * @param message the template used to create the message to be displayed for the error
7765 * @param correction the template used to create the correction to be displaye d for the error 7784 * @param correction the template used to create the correction to be displaye d for the error
7766 */ 7785 */
7767 const ParserErrorCode.con2(String name, int ordinal, this.errorSeverity, this. message, this.correction) : super(name, ordinal); 7786 ParserErrorCode.con2(String name, int ordinal, ErrorSeverity severity, String message, String correction) : super(name, ordinal) {
7787 this._severity = severity;
7788 this._message = message;
7789 this.correction8 = correction;
7790 }
7768 7791
7769 /** 7792 /**
7770 * Initialize a newly created error code to have the given message and a sever ity of ERROR. 7793 * Initialize a newly created error code to have the given message and a sever ity of ERROR.
7771 * 7794 *
7772 * @param message the message template used to create the message to be displa yed for the error 7795 * @param message the message template used to create the message to be displa yed for the error
7773 */ 7796 */
7774 const ParserErrorCode.con3(String name, int ordinal, String message) : this.co n2(name, ordinal, ErrorSeverity.ERROR, message, null); 7797 ParserErrorCode.con3(String name, int ordinal, String message) : this.con1(nam e, ordinal, ErrorSeverity.ERROR, message);
7798
7799 @override
7800 String get correction => correction8;
7801
7802 @override
7803 ErrorSeverity get errorSeverity => _severity;
7804
7805 @override
7806 String get message => _message;
7775 7807
7776 @override 7808 @override
7777 ErrorType get type => ErrorType.SYNTACTIC_ERROR; 7809 ErrorType get type => ErrorType.SYNTACTIC_ERROR;
7778 } 7810 }
7779 7811
7780 /** 7812 /**
7781 * Instances of the class `ResolutionCopier` copies resolution information from one AST 7813 * Instances of the class `ResolutionCopier` copies resolution information from one AST
7782 * structure to another as long as the structures of the corresponding children of a pair of nodes 7814 * structure to another as long as the structures of the corresponding children of a pair of nodes
7783 * are the same. 7815 * are the same.
7784 */ 7816 */
(...skipping 1177 matching lines...) Expand 10 before | Expand all | Expand 10 after
8962 return trampoline(target, arguments[0], arguments[1]); 8994 return trampoline(target, arguments[0], arguments[1]);
8963 case 3: 8995 case 3:
8964 return trampoline(target, arguments[0], arguments[1], arguments[2]); 8996 return trampoline(target, arguments[0], arguments[1], arguments[2]);
8965 case 4: 8997 case 4:
8966 return trampoline(target, arguments[0], arguments[1], arguments[2], argu ments[3]); 8998 return trampoline(target, arguments[0], arguments[1], arguments[2], argu ments[3]);
8967 default: 8999 default:
8968 throw new IllegalArgumentException("Not implemented for > 4 arguments"); 9000 throw new IllegalArgumentException("Not implemented for > 4 arguments");
8969 } 9001 }
8970 } 9002 }
8971 } 9003 }
OLDNEW
« no previous file with comments | « pkg/analyzer/lib/src/generated/java_core.dart ('k') | pkg/analyzer/lib/src/generated/resolver.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698