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

Unified Diff: vm/parser.cc

Issue 10697055: Represent tokens as a compressed stream instead of an array. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: Created 8 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « vm/parser.h ('k') | vm/raw_object.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: vm/parser.cc
===================================================================
--- vm/parser.cc (revision 9536)
+++ vm/parser.cc (working copy)
@@ -198,31 +198,6 @@
}
-bool TokenStreamIterator::IsValid() const {
- return !tokens_.IsNull();
-}
-
-
-Token::Kind TokenStreamIterator::CurrentTokenKind() const {
- return tokens_.KindAt(token_position_);
-}
-
-
-Token::Kind TokenStreamIterator::LookaheadTokenKind(intptr_t num_tokens) const {
- return tokens_.KindAt(token_position_ + num_tokens);
-}
-
-
-RawObject* TokenStreamIterator::CurrentToken() const {
- return tokens_.TokenAt(token_position_);
-}
-
-
-RawString* TokenStreamIterator::CurrentLiteral() const {
- return tokens_.LiteralAt(token_position_);
-}
-
-
struct Parser::Block : public ZoneAllocated {
Block(Block* outer_block, LocalScope* local_scope, SequenceNode* seq)
: parent(outer_block), scope(local_scope), statements(seq) {
@@ -358,9 +333,6 @@
TimerScope timer(FLAG_compiler_stats, &CompilerStats::parser_timer);
Parser parser(script, library);
parser.ParseTopLevel();
- if (FLAG_compiler_stats) {
- CompilerStats::num_tokens_total += parser.tokens_iterator_.NumberOfTokens();
- }
}
« no previous file with comments | « vm/parser.h ('k') | vm/raw_object.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698