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

Side by Side Diff: lib/dartdoc/frog/parser.dart

Issue 10559030: Remove uses of string + from API document generator. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Remove process_test.cc changes. Created 8 years, 6 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 | « lib/dartdoc/frog/library.dart ('k') | lib/dartdoc/frog/world.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) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 // TODO(jimhug): Error recovery needs major work! 5 // TODO(jimhug): Error recovery needs major work!
6 /** 6 /**
7 * A simple recursive descent parser for the dart language. 7 * A simple recursive descent parser for the dart language.
8 * 8 *
9 * This parser is designed to be more permissive than the official 9 * This parser is designed to be more permissive than the official
10 * Dart grammar. It is expected that many grammar errors would be 10 * Dart grammar. It is expected that many grammar errors would be
(...skipping 423 matching lines...) Expand 10 before | Expand all | Expand 10 after
434 int start = _peekToken.start; 434 int start = _peekToken.start;
435 var factoryToken = _next(); 435 var factoryToken = _next();
436 436
437 var names = [identifier()]; 437 var names = [identifier()];
438 while (_maybeEat(TokenKind.DOT)) { 438 while (_maybeEat(TokenKind.DOT)) {
439 names.add(identifier()); 439 names.add(identifier());
440 } 440 }
441 if (_peekKind(TokenKind.LT)) { 441 if (_peekKind(TokenKind.LT)) {
442 var tp = typeParameters(); 442 var tp = typeParameters();
443 world.warning('type parameters on factories are no longer supported, ' 443 world.warning('type parameters on factories are no longer supported, '
444 + 'place them on the class instead', _makeSpan(tp[0].span.start)); 444 'place them on the class instead', _makeSpan(tp[0].span.start));
445 } 445 }
446 446
447 var name = null; 447 var name = null;
448 var type = null; 448 var type = null;
449 if (_maybeEat(TokenKind.DOT)) { 449 if (_maybeEat(TokenKind.DOT)) {
450 name = identifier(); 450 name = identifier();
451 } else { 451 } else {
452 if (names.length > 1) { 452 if (names.length > 1) {
453 name = names.removeLast(); 453 name = names.removeLast();
454 } else { 454 } else {
(...skipping 1284 matching lines...) Expand 10 before | Expand all | Expand 10 after
1739 int _pos = 0; 1739 int _pos = 0;
1740 next() { 1740 next() {
1741 var token = tokens[_pos]; 1741 var token = tokens[_pos];
1742 ++_pos; 1742 ++_pos;
1743 if (_pos == tokens.length) { 1743 if (_pos == tokens.length) {
1744 parser.tokenizer = previousTokenizer; 1744 parser.tokenizer = previousTokenizer;
1745 } 1745 }
1746 return token; 1746 return token;
1747 } 1747 }
1748 } 1748 }
OLDNEW
« no previous file with comments | « lib/dartdoc/frog/library.dart ('k') | lib/dartdoc/frog/world.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698