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

Unified Diff: src/scanner.cc

Issue 5295004: Preparser extracted into separate files that can be compiled to a library. (Closed)
Patch Set: Cleanup of preparse class. Created 10 years, 1 month 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 | « src/scanner.h ('k') | src/scanner-base.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/scanner.cc
diff --git a/src/scanner.cc b/src/scanner.cc
index 63b2fd807d4d01eb80527be7a59bbdd15d69e688..d22ebc741fd482d19bcc7b098faf4616ff59dda9 100755
--- a/src/scanner.cc
+++ b/src/scanner.cc
@@ -164,22 +164,6 @@ void V8JavaScriptScanner::Initialize(Handle<String> source,
}
-Token::Value V8JavaScriptScanner::NextCheckStack() {
- // BUG 1215673: Find a thread safe way to set a stack limit in
- // pre-parse mode. Otherwise, we cannot safely pre-parse from other
- // threads.
- StackLimitCheck check;
- if (check.HasOverflowed()) {
- stack_overflow_ = true;
- current_ = next_;
- next_.token = Token::ILLEGAL;
- return current_.token;
- } else {
- return Next();
- }
-}
-
-
UTF16Buffer* StreamInitializer::Init(Handle<String> source,
unibrow::CharacterStream* stream,
int start_position,
@@ -236,13 +220,7 @@ Token::Value JsonScanner::Next() {
// threads.
current_ = next_;
// Check for stack-overflow before returning any tokens.
- StackLimitCheck check;
- if (check.HasOverflowed()) {
- stack_overflow_ = true;
- next_.token = Token::ILLEGAL;
- } else {
- ScanJson();
- }
+ ScanJson();
return current_.token;
}
« no previous file with comments | « src/scanner.h ('k') | src/scanner-base.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698