| OLD | NEW |
| 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 library analyzer.src.generated.parser; | 5 library analyzer.src.generated.parser; |
| 6 | 6 |
| 7 import 'dart:collection'; | 7 import 'dart:collection'; |
| 8 import "dart:math" as math; | 8 import "dart:math" as math; |
| 9 | 9 |
| 10 import 'package:analyzer/src/generated/ast.dart'; | 10 import 'package:analyzer/src/generated/ast.dart'; |
| (...skipping 9363 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 9374 * identifiers async, await, or yield is used as an identifier in a function | 9374 * identifiers async, await, or yield is used as an identifier in a function |
| 9375 * body marked with either async, async*, or sync*. | 9375 * body marked with either async, async*, or sync*. |
| 9376 */ | 9376 */ |
| 9377 static const ParserErrorCode ASYNC_KEYWORD_USED_AS_IDENTIFIER = | 9377 static const ParserErrorCode ASYNC_KEYWORD_USED_AS_IDENTIFIER = |
| 9378 const ParserErrorCode('ASYNC_KEYWORD_USED_AS_IDENTIFIER', | 9378 const ParserErrorCode('ASYNC_KEYWORD_USED_AS_IDENTIFIER', |
| 9379 "The keywords 'async', 'await', and 'yield' may not be used as identif
iers in an asynchronous or generator function."); | 9379 "The keywords 'async', 'await', and 'yield' may not be used as identif
iers in an asynchronous or generator function."); |
| 9380 | 9380 |
| 9381 /** | 9381 /** |
| 9382 * Some environments, such as Fletch, do not support async. | 9382 * Some environments, such as Fletch, do not support async. |
| 9383 */ | 9383 */ |
| 9384 static const CompileTimeErrorCode ASYNC_NOT_SUPPORTED = | 9384 static const ParserErrorCode ASYNC_NOT_SUPPORTED = |
| 9385 const CompileTimeErrorCode('ASYNC_NOT_SUPPORTED', | 9385 const ParserErrorCode('ASYNC_NOT_SUPPORTED', |
| 9386 "Async and sync are not supported in this environment."); | 9386 "Async and sync are not supported in this environment."); |
| 9387 | 9387 |
| 9388 static const ParserErrorCode BREAK_OUTSIDE_OF_LOOP = const ParserErrorCode( | 9388 static const ParserErrorCode BREAK_OUTSIDE_OF_LOOP = const ParserErrorCode( |
| 9389 'BREAK_OUTSIDE_OF_LOOP', | 9389 'BREAK_OUTSIDE_OF_LOOP', |
| 9390 "A break statement cannot be used outside of a loop or switch statement"); | 9390 "A break statement cannot be used outside of a loop or switch statement"); |
| 9391 | 9391 |
| 9392 static const ParserErrorCode CLASS_IN_CLASS = const ParserErrorCode( | 9392 static const ParserErrorCode CLASS_IN_CLASS = const ParserErrorCode( |
| 9393 'CLASS_IN_CLASS', "Classes cannot be declared inside other classes"); | 9393 'CLASS_IN_CLASS', "Classes cannot be declared inside other classes"); |
| 9394 | 9394 |
| 9395 static const ParserErrorCode COLON_IN_PLACE_OF_IN = const ParserErrorCode( | 9395 static const ParserErrorCode COLON_IN_PLACE_OF_IN = const ParserErrorCode( |
| (...skipping 1960 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 11356 } | 11356 } |
| 11357 | 11357 |
| 11358 /** | 11358 /** |
| 11359 * Copy resolution data from the [fromNode] to the [toNode]. | 11359 * Copy resolution data from the [fromNode] to the [toNode]. |
| 11360 */ | 11360 */ |
| 11361 static void copyResolutionData(AstNode fromNode, AstNode toNode) { | 11361 static void copyResolutionData(AstNode fromNode, AstNode toNode) { |
| 11362 ResolutionCopier copier = new ResolutionCopier(); | 11362 ResolutionCopier copier = new ResolutionCopier(); |
| 11363 copier._isEqualNodes(fromNode, toNode); | 11363 copier._isEqualNodes(fromNode, toNode); |
| 11364 } | 11364 } |
| 11365 } | 11365 } |
| OLD | NEW |