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

Unified Diff: runtime/vm/object_test.cc

Issue 1969563002: Eliminate GrowableTokenStream (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 7 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 | « runtime/vm/object.cc ('k') | runtime/vm/scanner.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object_test.cc
diff --git a/runtime/vm/object_test.cc b/runtime/vm/object_test.cc
index 7d9be08654a2c2a9afe51ec9d2009e8a67c13eb8..6c0d3b9b0be88dc85705e6b0aa148d912a33a74c 100644
--- a/runtime/vm/object_test.cc
+++ b/runtime/vm/object_test.cc
@@ -165,14 +165,9 @@ VM_TEST_CASE(TokenStream) {
Zone* zone = Thread::Current()->zone();
String& source = String::Handle(zone, String::New("= ( 9 , ."));
String& private_key = String::Handle(zone, String::New(""));
- Scanner scanner(source, private_key);
- const Scanner::GrowableTokenStream& ts = scanner.GetStream();
- EXPECT_EQ(6, ts.length());
- EXPECT_EQ(Token::kLPAREN, ts[1].kind);
const TokenStream& token_stream = TokenStream::Handle(
- zone, TokenStream::New(ts, private_key, false));
+ zone, TokenStream::New(source, private_key, false));
TokenStream::Iterator iterator(zone, token_stream, TokenPosition::kMinSource);
- // EXPECT_EQ(6, token_stream.Length());
iterator.Advance(); // Advance to '(' token.
EXPECT_EQ(Token::kLPAREN, iterator.CurrentTokenKind());
iterator.Advance();
« no previous file with comments | « runtime/vm/object.cc ('k') | runtime/vm/scanner.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698