| 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 // 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 "dart:math" as math; | 10 import "dart:math" as math; |
| (...skipping 5720 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5731 } | 5731 } |
| 5732 SimpleIdentifier name = parseSimpleIdentifier(); | 5732 SimpleIdentifier name = parseSimpleIdentifier(); |
| 5733 FormalParameterList parameters = null; | 5733 FormalParameterList parameters = null; |
| 5734 if (!isGetter) { | 5734 if (!isGetter) { |
| 5735 if (_matches(TokenType.OPEN_PAREN)) { | 5735 if (_matches(TokenType.OPEN_PAREN)) { |
| 5736 parameters = parseFormalParameterList(); | 5736 parameters = parseFormalParameterList(); |
| 5737 _validateFormalParameterList(parameters); | 5737 _validateFormalParameterList(parameters); |
| 5738 } else { | 5738 } else { |
| 5739 _reportErrorForCurrentToken( | 5739 _reportErrorForCurrentToken( |
| 5740 ParserErrorCode.MISSING_FUNCTION_PARAMETERS); | 5740 ParserErrorCode.MISSING_FUNCTION_PARAMETERS); |
| 5741 parameters = new FormalParameterList( |
| 5742 _createSyntheticToken(TokenType.OPEN_PAREN), null, null, null, |
| 5743 _createSyntheticToken(TokenType.CLOSE_PAREN)); |
| 5741 } | 5744 } |
| 5742 } else if (_matches(TokenType.OPEN_PAREN)) { | 5745 } else if (_matches(TokenType.OPEN_PAREN)) { |
| 5743 _reportErrorForCurrentToken(ParserErrorCode.GETTER_WITH_PARAMETERS); | 5746 _reportErrorForCurrentToken(ParserErrorCode.GETTER_WITH_PARAMETERS); |
| 5744 parseFormalParameterList(); | 5747 parseFormalParameterList(); |
| 5745 } | 5748 } |
| 5746 FunctionBody body; | 5749 FunctionBody body; |
| 5747 if (externalKeyword == null) { | 5750 if (externalKeyword == null) { |
| 5748 body = _parseFunctionBody( | 5751 body = _parseFunctionBody( |
| 5749 false, ParserErrorCode.MISSING_FUNCTION_BODY, false); | 5752 false, ParserErrorCode.MISSING_FUNCTION_BODY, false); |
| 5750 } else { | 5753 } else { |
| (...skipping 4789 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 10540 } | 10543 } |
| 10541 | 10544 |
| 10542 /** | 10545 /** |
| 10543 * Copy resolution data from the [fromNode] to the [toNode]. | 10546 * Copy resolution data from the [fromNode] to the [toNode]. |
| 10544 */ | 10547 */ |
| 10545 static void copyResolutionData(AstNode fromNode, AstNode toNode) { | 10548 static void copyResolutionData(AstNode fromNode, AstNode toNode) { |
| 10546 ResolutionCopier copier = new ResolutionCopier(); | 10549 ResolutionCopier copier = new ResolutionCopier(); |
| 10547 copier._isEqualNodes(fromNode, toNode); | 10550 copier._isEqualNodes(fromNode, toNode); |
| 10548 } | 10551 } |
| 10549 } | 10552 } |
| OLD | NEW |