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

Unified Diff: src/parsing/parser.cc

Issue 2687973003: Revert of [Compiler] Enable handles created during parsing and scope analysis to be deferred. (Closed)
Patch Set: Created 3 years, 10 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 | « src/parsing/parser.h ('k') | src/parsing/parsing.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/parsing/parser.cc
diff --git a/src/parsing/parser.cc b/src/parsing/parser.cc
index a90201173cf69e596a3c50e2726c84731604b6d1..805b6ef066bfe5ea0cd4669cf2ad2a387b022873 100644
--- a/src/parsing/parser.cc
+++ b/src/parsing/parser.cc
@@ -3361,18 +3361,21 @@
}
}
-void Parser::ReportErrors(Isolate* isolate, Handle<Script> script) {
- if (stack_overflow()) {
- isolate->StackOverflow();
- } else {
- DCHECK(pending_error_handler_.has_pending_error());
- // Internalize ast values for throwing the pending error.
- ast_value_factory()->Internalize(isolate);
- pending_error_handler_.ThrowPendingError(isolate, script);
- }
-}
-
-void Parser::UpdateStatistics(Isolate* isolate, Handle<Script> script) {
+
+void Parser::Internalize(Isolate* isolate, Handle<Script> script, bool error) {
+ // Internalize strings and values.
+ ast_value_factory()->Internalize(isolate);
+
+ // Error processing.
+ if (error) {
+ if (stack_overflow()) {
+ isolate->StackOverflow();
+ } else {
+ DCHECK(pending_error_handler_.has_pending_error());
+ pending_error_handler_.ThrowPendingError(isolate, script);
+ }
+ }
+
// Move statistics to Isolate.
for (int feature = 0; feature < v8::Isolate::kUseCounterFeatureCount;
++feature) {
« no previous file with comments | « src/parsing/parser.h ('k') | src/parsing/parsing.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698