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

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

Issue 1072663002: (TBR) Fix import parsing (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 8 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
« no previous file with comments | « no previous file | pkg/analyzer/test/generated/parser_test.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "dart:math" as math; 10 import "dart:math" as math;
(...skipping 5951 matching lines...) Expand 10 before | Expand all | Expand 10 after
5962 SimpleIdentifier prefix = null; 5962 SimpleIdentifier prefix = null;
5963 if (_matchesKeyword(Keyword.DEFERRED)) { 5963 if (_matchesKeyword(Keyword.DEFERRED)) {
5964 deferredToken = getAndAdvance(); 5964 deferredToken = getAndAdvance();
5965 } 5965 }
5966 if (_matchesKeyword(Keyword.AS)) { 5966 if (_matchesKeyword(Keyword.AS)) {
5967 asToken = getAndAdvance(); 5967 asToken = getAndAdvance();
5968 prefix = parseSimpleIdentifier(); 5968 prefix = parseSimpleIdentifier();
5969 } else if (deferredToken != null) { 5969 } else if (deferredToken != null) {
5970 _reportErrorForCurrentToken( 5970 _reportErrorForCurrentToken(
5971 ParserErrorCode.MISSING_PREFIX_IN_DEFERRED_IMPORT); 5971 ParserErrorCode.MISSING_PREFIX_IN_DEFERRED_IMPORT);
5972 } else if (!_matches(TokenType.SEMICOLON)) { 5972 } else if (!_matches(TokenType.SEMICOLON) &&
5973 !_matchesString(_SHOW) &&
5974 !_matchesString(_HIDE)) {
5973 Token nextToken = _peek(); 5975 Token nextToken = _peek();
5974 if (_tokenMatchesKeyword(nextToken, Keyword.AS) || 5976 if (_tokenMatchesKeyword(nextToken, Keyword.AS) ||
5975 _tokenMatchesString(nextToken, _SHOW) || 5977 _tokenMatchesString(nextToken, _SHOW) ||
5976 _tokenMatchesString(nextToken, _HIDE)) { 5978 _tokenMatchesString(nextToken, _HIDE)) {
5977 _reportErrorForCurrentToken( 5979 _reportErrorForCurrentToken(
5978 ParserErrorCode.UNEXPECTED_TOKEN, [_currentToken]); 5980 ParserErrorCode.UNEXPECTED_TOKEN, [_currentToken]);
5979 _advance(); 5981 _advance();
5980 if (_matchesKeyword(Keyword.AS)) { 5982 if (_matchesKeyword(Keyword.AS)) {
5981 asToken = getAndAdvance(); 5983 asToken = getAndAdvance();
5982 prefix = parseSimpleIdentifier(); 5984 prefix = parseSimpleIdentifier();
(...skipping 4593 matching lines...) Expand 10 before | Expand all | Expand 10 after
10576 } 10578 }
10577 10579
10578 /** 10580 /**
10579 * Copy resolution data from the [fromNode] to the [toNode]. 10581 * Copy resolution data from the [fromNode] to the [toNode].
10580 */ 10582 */
10581 static void copyResolutionData(AstNode fromNode, AstNode toNode) { 10583 static void copyResolutionData(AstNode fromNode, AstNode toNode) {
10582 ResolutionCopier copier = new ResolutionCopier(); 10584 ResolutionCopier copier = new ResolutionCopier();
10583 copier._isEqualNodes(fromNode, toNode); 10585 copier._isEqualNodes(fromNode, toNode);
10584 } 10586 }
10585 } 10587 }
OLDNEW
« no previous file with comments | « no previous file | pkg/analyzer/test/generated/parser_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698